@ipcom/asterisk-ari 0.0.157 → 0.0.158
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/dist/esm/index.js
CHANGED
|
@@ -3297,7 +3297,6 @@ var WebSocketClient = class extends EventEmitter4 {
|
|
|
3297
3297
|
(event) => queryParams.append("event", event)
|
|
3298
3298
|
);
|
|
3299
3299
|
this.lastWsUrl = `${protocol}://${encodeURIComponent(username)}:${encodeURIComponent(password)}@${normalizedHost}/ari/events?${queryParams.toString()}`;
|
|
3300
|
-
console.log("Connecting to WebSocket...");
|
|
3301
3300
|
try {
|
|
3302
3301
|
await this.initializeWebSocket(this.lastWsUrl);
|
|
3303
3302
|
} finally {
|
|
@@ -3325,7 +3324,6 @@ var WebSocketClient = class extends EventEmitter4 {
|
|
|
3325
3324
|
try {
|
|
3326
3325
|
this.ws = new WebSocket(wsUrl);
|
|
3327
3326
|
this.ws.once("open", () => {
|
|
3328
|
-
console.log("WebSocket connection established successfully");
|
|
3329
3327
|
this.setupHeartbeat();
|
|
3330
3328
|
if (this.isReconnecting) {
|
|
3331
3329
|
this.emit("reconnected", {
|
|
@@ -3652,7 +3650,6 @@ var AriClient = class {
|
|
|
3652
3650
|
this
|
|
3653
3651
|
);
|
|
3654
3652
|
await this.webSocketClient.connect();
|
|
3655
|
-
console.log("WebSocket connection established successfully.");
|
|
3656
3653
|
} catch (error) {
|
|
3657
3654
|
console.error("Failed to establish WebSocket connection:", error);
|
|
3658
3655
|
this.webSocketClient = void 0;
|
|
@@ -3662,7 +3659,7 @@ var AriClient = class {
|
|
|
3662
3659
|
/**
|
|
3663
3660
|
* Destroys the ARI Client instance, cleaning up all resources and removing circular references.
|
|
3664
3661
|
* This method should be called when the ARI Client is no longer needed to ensure proper cleanup.
|
|
3665
|
-
*
|
|
3662
|
+
*
|
|
3666
3663
|
* @returns {Promise<void>} A promise that resolves when the destruction process is complete.
|
|
3667
3664
|
* @throws {Error} If an error occurs during the destruction process.
|
|
3668
3665
|
*/
|
|
@@ -3703,7 +3700,6 @@ var AriClient = class {
|
|
|
3703
3700
|
this.webSocketClient.on(event, listener);
|
|
3704
3701
|
existingListeners.push(listener);
|
|
3705
3702
|
this.eventListeners.set(event, existingListeners);
|
|
3706
|
-
console.log(`Event listener successfully registered for ${event}`);
|
|
3707
3703
|
}
|
|
3708
3704
|
/**
|
|
3709
3705
|
* Registers a one-time event listener for WebSocket events.
|