NathanaelA / nativescript-websockets

Websockets for NativeScript
83 stars 43 forks source link

Exception error when device go to offline and disconnect from server #80

Closed luiguild closed 3 years ago

luiguild commented 4 years ago

Anyone knows more about this error? This occurs whenever device turn to flight mode or disconnect from internet both 3G or WIFI

System.err: An uncaught Exception occurred on "main" thread. System.err: Calling js method onError failed System.err: TypeError: eventCallbacks[i].c.apply is not a function System.err: System.err: StackTrace: System.err: push.../node_modules/nativescript-websockets/websockets.android.js.NativeWebSockets._notify(file:///node_modules\nativescript-websockets\websockets.android.js:358:31) System.err: at onError(file:///node_modules\nativescript-websockets\websockets.android.js:168:25) System.err: at com.tns.Runtime.callJSMethodNative(Native Method) System.err: at com.tns.Runtime.access$2300(Runtime.java:39) System.err: at com.tns.Runtime$5.run(Runtime.java:1307) System.err: at android.os.Handler.handleCallback(Handler.java:873) System.err: at android.os.Handler.dispatchMessage(Handler.java:99) System.err: at android.os.Looper.loop(Looper.java:193) System.err: at android.app.ActivityThread.main(ActivityThread.java:6923) System.err: at java.lang.reflect.Method.invoke(Native Method) System.err: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493) System.err: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:870)

NathanaelA commented 3 years ago

Please let me know if this is still happening w/ v2.0 and if you can cause the demo to fail...