Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@evergis/api

Package Overview
Dependencies
Maintainers
6
Versions
329
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@evergis/api - npm Package Compare versions

Comparing version 0.1.21 to 0.1.22

2

es/services/Notification.d.ts

@@ -9,2 +9,3 @@ import { NotificationService } from '../__generated__/NotificationService';

private wsUrl?;
private reconnectCount;
constructor(info: ServiceInfoDc, http: IHttpClient);

@@ -17,3 +18,2 @@ on<Data, Result>(tag: string, handler: NotificationHandler<Data, Result>): void;

private connect;
private onWsConnected;
private onWsClosed;

@@ -20,0 +20,0 @@ private onWsMessage;

@@ -6,8 +6,10 @@ import { NotificationService } from '../__generated__/NotificationService';

super(info, http);
this.onWsConnected = () => {
console.log('WebSocket connection established.');
};
this.onWsClosed = () => {
console.log('WebSocket connection closed.');
this.connect();
if (this.reconnectCount < 5) {
this.connect();
this.reconnectCount += 1;
}
else {
console.log("Unable to connect via websocket after 5 attempts");
}
};

@@ -28,2 +30,3 @@ this.onWsMessage = (event) => {

this.emitter = new EventEmitter();
this.reconnectCount = 0;
}

@@ -59,3 +62,2 @@ on(tag, handler) {

this.ws = new WebSocket(this.wsUrl);
this.ws.onopen = this.onWsConnected;
this.ws.onclose = this.onWsClosed;

@@ -62,0 +64,0 @@ this.ws.onmessage = this.onWsMessage;

{
"name": "@evergis/api",
"version": "0.1.21",
"version": "0.1.22",
"license": "ISC",

@@ -5,0 +5,0 @@ "author": "everpoint",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc