capacitor-websocket-client icon indicating copy to clipboard operation
capacitor-websocket-client copied to clipboard

flash exit on android

Open c445352742 opened this issue 8 months ago • 6 comments

1 when i get in vue , connected to ws,and then call App.exit(), it's fine. 2 when i get in my app again later, it just flash exit. And android keep repeat these two steps, even in emulator.

Android error is: Trace: java.lang.NullPointerException: Attempt to invoke virtual method 'void com.getcapacitor.PluginCall.successCallback(com.getcapacitor.PluginResult)'on a nulobject reference at cn.holmescraft.capacitor.plugins.websocket.client.WebSocket$createConnect$wsClient$1.onFailure(WebSocket.kt:65)

my fix is annotate the code in line 65 : // bridge.getSavedCall(failureCallId[id]).successCallback(PluginResult(ret))

Can i get a good fix about it?

c445352742 avatar Jun 10 '24 16:06 c445352742