webitel-sdk 26.4.29 → 26.4.31
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/index.cjs +7 -2
- package/index.cjs.map +1 -1
- package/index.mjs +7 -2
- package/index.mjs.map +1 -1
- package/package.json +1 -1
- package/socket/socket.d.ts.map +1 -1
- package/version.d.ts +1 -1
package/index.cjs
CHANGED
|
@@ -66728,7 +66728,7 @@ _defineProperty(SipPhone$1, "userAgent", `Webitel-Phone/${version$1}`);
|
|
|
66728
66728
|
_defineProperty(SipPhone$1, "sipVersion", version$1);
|
|
66729
66729
|
//#endregion
|
|
66730
66730
|
//#region src/version.ts
|
|
66731
|
-
const version = "26.4.
|
|
66731
|
+
const version = "26.4.31";
|
|
66732
66732
|
//#endregion
|
|
66733
66733
|
//#region src/socket/errors.ts
|
|
66734
66734
|
/**
|
|
@@ -69985,7 +69985,7 @@ var Conversation = class {
|
|
|
69985
69985
|
*/
|
|
69986
69986
|
messageMember(msg) {
|
|
69987
69987
|
if (this.member && msg.channel_id === this.channelId) return { self: true };
|
|
69988
|
-
for (const m of this.members) if (m.id === msg.channel_id) return m;
|
|
69988
|
+
for (const m of this.members) if (msg.channel_id !== "" && m.id === msg.channel_id) return m;
|
|
69989
69989
|
return null;
|
|
69990
69990
|
}
|
|
69991
69991
|
};
|
|
@@ -70042,6 +70042,11 @@ var Socket = class extends ee_ts.EventEmitter {
|
|
|
70042
70042
|
* @param code Код закриття з'єднання (необов'язково).
|
|
70043
70043
|
*/
|
|
70044
70044
|
close(code) {
|
|
70045
|
+
if (!this.socket) {
|
|
70046
|
+
const stackTrace = (/* @__PURE__ */ new Error("Socket is not open")).stack;
|
|
70047
|
+
console.warn(`Socket is not open\n`, stackTrace);
|
|
70048
|
+
return;
|
|
70049
|
+
}
|
|
70045
70050
|
this.socket.close(code || 1e3);
|
|
70046
70051
|
delete this.socket;
|
|
70047
70052
|
this.onClose(code || 1e3);
|