Simplifying if condition

This commit is contained in:
David Négrier 2022-01-19 15:45:16 +01:00 committed by GitHub
parent 30811e7702
commit fd88399938
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -261,7 +261,7 @@ export class VideoPeer extends Peer {
this.closing = true; this.closing = true;
this.onBlockSubscribe.unsubscribe(); this.onBlockSubscribe.unsubscribe();
this.onUnBlockSubscribe.unsubscribe(); this.onUnBlockSubscribe.unsubscribe();
if (this.newMessageSubscribtion) this.newMessageSubscribtion.unsubscribe(); this.newMessageSubscribtion?.unsubscribe();
chatMessagesStore.addOutcomingUser(this.userId); chatMessagesStore.addOutcomingUser(this.userId);
if (this.localStreamStoreSubscribe) this.localStreamStoreSubscribe(); if (this.localStreamStoreSubscribe) this.localStreamStoreSubscribe();
if (this.obtainedMediaConstraintStoreSubscribe) this.obtainedMediaConstraintStoreSubscribe(); if (this.obtainedMediaConstraintStoreSubscribe) this.obtainedMediaConstraintStoreSubscribe();