@ives_xxz/framework 2.3.1 → 2.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -88,6 +88,8 @@ export default class FWSocket extends FW.Service implements FW.Socket {
|
|
|
88
88
|
cc.assetManager.cacheManager.getTemp(url) ||
|
|
89
89
|
url;
|
|
90
90
|
}
|
|
91
|
+
|
|
92
|
+
FW.Log.debug("创建socket链接", address, url, JSON.stringify(config));
|
|
91
93
|
//@ts-ignore
|
|
92
94
|
this.socket = new WebSocket(address, [], url);
|
|
93
95
|
} else {
|
|
@@ -96,7 +98,10 @@ export default class FWSocket extends FW.Service implements FW.Socket {
|
|
|
96
98
|
}
|
|
97
99
|
this.socket.onopen = this.onSocketOpen.bind(this);
|
|
98
100
|
this.socket.onclose = this.onSocketClose.bind(this);
|
|
99
|
-
this.socket.onerror =
|
|
101
|
+
this.socket.onerror = (msg) => {
|
|
102
|
+
FW.Log.error("触发error消息");
|
|
103
|
+
this.onSocketError(msg);
|
|
104
|
+
};
|
|
100
105
|
this.socket.onmessage = this.onSocketMessage.bind(this);
|
|
101
106
|
|
|
102
107
|
this.socketSender = socketSender;
|