Socket
Socket
Sign inDemoInstall

resilient-websocket

Package Overview
Dependencies
0
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.8 to 1.0.9

1

dist/ResilientWebSocket.d.ts

@@ -40,2 +40,3 @@ export interface OnCallback {

on: (event: WebSocketEvent, callback: OnCallback) => void;
off: (event: WebSocketEvent, callback: OnCallback) => void;
private respondToCallbacks;

@@ -42,0 +43,0 @@ private onOpen;

10

dist/ResilientWebSocket.js

@@ -58,5 +58,5 @@ "use strict";

_this.socket.removeEventListener('open', _this.onOpen);
_this.socket.removeEventListener('close', _this.onClose);
_this.socket.close();
// Allow this to fire first
_this.socket.removeEventListener('close', _this.onClose);
_this.respondToCallbacks(WebSocketEvent.CLOSE, event);
};

@@ -71,2 +71,8 @@ this.on = function (event, callback) {

};
this.off = function (event, callback) {
var callbackList = _this.callbacks.get(event);
if (callbackList) {
callbackList.delete(callback);
}
};
this.respondToCallbacks = function (event, data) {

@@ -73,0 +79,0 @@ var callbacks = _this.callbacks.get(event);

{
"name": "resilient-websocket",
"version": "1.0.8",
"version": "1.0.9",
"description": "A client WebSocket wrapper with support for reconnection and ping/pong",

@@ -5,0 +5,0 @@ "main": "dist/ResilientWebSocket.js",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc