updated js code arrayBufferToString
This commit is contained in:
parent
59585883d3
commit
fbc8e5decd
|
@ -6,6 +6,8 @@
|
|||
- Fixed iOS `findNext`
|
||||
- Fixed Android `RendererPriorityPolicy.waivedWhenNotVisible` type 'Null' is not a subtype of type 'bool'
|
||||
- Fixed iOS 14.0 crash when calling `callAsyncJavaScript` method
|
||||
- Merged "Android fix leaking MethodChannel through anonymous class" [#1201](https://github.com/pichillilorenzo/flutter_inappwebview/pull/1201) (thanks to [emakar](https://github.com/emakar))
|
||||
- Merged "Fix RangeError: Maximum call stack size exceeded" [#1208](https://github.com/pichillilorenzo/flutter_inappwebview/pull/1208) (thanks to [liasica](https://github.com/liasica))
|
||||
|
||||
## 5.4.4+3
|
||||
|
||||
|
|
|
@ -147,9 +147,8 @@ public class JavaScriptBridgeJS {
|
|||
" });" +
|
||||
" }," +
|
||||
" arrayBufferToString: function(arrayBuffer) {" +
|
||||
" const uint8Array = new Uint8Array(arrayBuffer);" +
|
||||
" const data = uint8Array.reduce(function(acc, i) { return acc += String.fromCharCode.apply(null, [i]); }, '');" +
|
||||
" return data;" +
|
||||
" var uint8Array = new Uint8Array(arrayBuffer);" +
|
||||
" return uint8Array.reduce(function(acc, i) { return acc += String.fromCharCode.apply(null, [i]); }, '');" +
|
||||
" }," +
|
||||
" isBodyFormData: function(bodyString) {" +
|
||||
" return bodyString.indexOf('------WebKitFormBoundary') >= 0;" +
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
archiveVersion = 1;
|
||||
classes = {
|
||||
};
|
||||
objectVersion = 46;
|
||||
objectVersion = 50;
|
||||
objects = {
|
||||
|
||||
/* Begin PBXBuildFile section */
|
||||
|
|
|
@ -175,9 +175,8 @@ let UTIL_JS_SOURCE = """
|
|||
});
|
||||
},
|
||||
arrayBufferToString: function(arrayBuffer) {
|
||||
const uint8Array = new Uint8Array(arrayBuffer);
|
||||
const data = uint8Array.reduce(function(acc, i) { return acc += String.fromCharCode.apply(null, [i]); }, '');
|
||||
return data;
|
||||
var uint8Array = new Uint8Array(arrayBuffer);
|
||||
return uint8Array.reduce(function(acc, i) { return acc += String.fromCharCode.apply(null, [i]); }, '');
|
||||
},
|
||||
isBodyFormData: function(bodyString) {
|
||||
return bodyString.indexOf('------WebKitFormBoundary') >= 0;
|
||||
|
|
Loading…
Reference in New Issue