From ad67886f966713fcbcaa5e709b82afa09798afc8 Mon Sep 17 00:00:00 2001 From: syuilo Date: Thu, 11 Oct 2018 22:35:34 +0900 Subject: [PATCH] Resolve #543 --- src/client/app/common/scripts/stream.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/client/app/common/scripts/stream.ts b/src/client/app/common/scripts/stream.ts index 3fbfa4b631..7456c0b074 100644 --- a/src/client/app/common/scripts/stream.ts +++ b/src/client/app/common/scripts/stream.ts @@ -89,8 +89,10 @@ export default class Stream extends EventEmitter { */ @autobind private onClose() { - this.state = 'reconnecting'; - this.emit('_disconnected_'); + if (this.state == 'connected') { + this.state = 'reconnecting'; + this.emit('_disconnected_'); + } } /**