otter-bridge
Advanced tools
Comparing version 0.1.0-beta.2 to 0.1.0-beta.3
{ | ||
"name": "otter-bridge", | ||
"version": "0.1.0-beta.2", | ||
"version": "0.1.0-beta.3", | ||
"description": "Otter game web jsbridge", | ||
@@ -5,0 +5,0 @@ "files": [ |
@@ -47,12 +47,7 @@ import URI from "urijs"; | ||
if (!this.valid) { | ||
try { | ||
if (navigator.userAgent?.indexOf("OtterGamePlatform") < 0) { | ||
console.error("Not in Otter Game Platform App"); | ||
return false; | ||
} | ||
const envRes = await this._waitForEnvReady(); | ||
console.log("bridgeInit", envRes); | ||
} catch (e) { | ||
throw e; | ||
if (navigator.userAgent?.indexOf("OtterGamePlatform") < 0) { | ||
throw "Not in Otter Game Platform App"; | ||
} | ||
const envRes = await this._waitForEnvReady(); | ||
console.log("bridgeInit", envRes); | ||
} | ||
@@ -116,3 +111,3 @@ return await (window as any).flutter_inappwebview.callHandler( | ||
window.addEventListener("error", (e) => { | ||
const { message, filename , lineno, colno, error } = e; | ||
const { message, filename, lineno, colno, error } = e; | ||
const stack = error?.stack; | ||
@@ -119,0 +114,0 @@ const errorInfo = { |
55980
1031