OP-2481 Cleanup

This commit is contained in:
Dmitry Leleko
2022-06-30 15:21:35 +03:00
parent ccff8058e5
commit 2b3d2b8db5
2 changed files with 4 additions and 4 deletions

View File

@@ -74,7 +74,7 @@ export default class PriceFeedSubscription<T extends SubscriptionType = Subscrip
readonly type: T;
private isClosedIntentionally: boolean = false;
private isClosedIntentionally = false;
constructor(
type: T,
@@ -108,7 +108,7 @@ export default class PriceFeedSubscription<T extends SubscriptionType = Subscrip
this.callback(parseResult.data);
};
this.ws.onclose = (e) => {
this.ws.onclose = () => {
if (this.heartbeatInterval) clearInterval(this.heartbeatInterval);
if (!this.isClosedIntentionally) this.init();
};