Skip to content

Commit 669ea8c

Browse files
committed
Don't stop the game on browser extension's error
1 parent 507b459 commit 669ea8c

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

js/rpg_managers/SceneManager.js

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -151,12 +151,14 @@ SceneManager.terminate = function() {
151151

152152
SceneManager.onError = function(e) {
153153
console.error(e.message);
154-
console.error(e.filename, e.lineno);
155-
try {
156-
this.stop();
157-
Graphics.printError('Error', e.message);
158-
AudioManager.stopAll();
159-
} catch (e2) {
154+
if (e.filename || e.lineno) {
155+
console.error(e.filename, e.lineno);
156+
try {
157+
this.stop();
158+
Graphics.printError('Error', e.message);
159+
AudioManager.stopAll();
160+
} catch (e2) {
161+
}
160162
}
161163
};
162164

0 commit comments

Comments
 (0)