Skip to content

Commit f179e90

Browse files
author
鲁盛杰
committed
fix arrow function not working on old version Android webview
1 parent 8bcb6a6 commit f179e90

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/jsBuilder.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ export const getJavascriptSource = (props) => {
7676
}
7777
7878
function toString (obj) {
79-
var result = JSON.stringify(obj, (key, val) => {
79+
var result = JSON.stringify(obj, function (key, val) {
8080
if (typeof val === 'function') {
8181
return val.toString();
8282
}
@@ -105,7 +105,9 @@ export const getJavascriptSource = (props) => {
105105
var data = {};
106106
107107
if(req.properties !== undefined) {
108-
req.properties.forEach((prop) => data[prop] = option[prop]);
108+
req.properties.forEach(function (prop) {
109+
data[prop] = option[prop];
110+
});
109111
} else {
110112
var data = {
111113
option: option

0 commit comments

Comments
 (0)