Commit f8a64b5d by pye52

保证websocket client只初始化一次

parent 6b3ab98a
......@@ -62,6 +62,7 @@ public class SCWebSocketClient extends WebSocketClient {
}
public static void init(URI serverUri, String deviceSN, Gson gson) {
if (instance != null) return;
instance = new SCWebSocketClient(serverUri, deviceSN, gson);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment