mirror of
https://github.com/m1k1o/neko.git
synced 2024-07-24 14:40:50 +12:00
set as disconnected only if not connecting.
This commit is contained in:
parent
5c8c8c1330
commit
f6edb4208e
@ -44,7 +44,7 @@ export class NekoConnection extends EventEmitter<NekoConnectionEvents> {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.websocket.on('disconnected', () => {
|
this.websocket.on('disconnected', () => {
|
||||||
if (this._state.status !== 'disconnected') {
|
if (this._state.status === 'connected') {
|
||||||
Vue.set(this._state, 'status', 'disconnected')
|
Vue.set(this._state, 'status', 'disconnected')
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -63,7 +63,7 @@ export class NekoConnection extends EventEmitter<NekoConnectionEvents> {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.webrtc.on('disconnected', () => {
|
this.webrtc.on('disconnected', () => {
|
||||||
if (this._state.status !== 'disconnected') {
|
if (this._state.status === 'connected') {
|
||||||
Vue.set(this._state, 'status', 'disconnected')
|
Vue.set(this._state, 'status', 'disconnected')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user