mirror of
https://github.com/m1k1o/neko.git
synced 2025-06-13 08:12:57 +02:00
reconnect only after succesfull connection.
This commit is contained in:
parent
c49c9ad4de
commit
45c6c33647
1 changed files with 2 additions and 2 deletions
|
@ -123,8 +123,6 @@ export class NekoConnection extends EventEmitter<NekoConnectionEvents> {
|
|||
}
|
||||
|
||||
public async connect(video?: string): Promise<void> {
|
||||
this._shouldReconnect = true
|
||||
|
||||
await this._websocketConnect()
|
||||
|
||||
if (video && !this._state.webrtc.videos.includes(video)) {
|
||||
|
@ -132,6 +130,8 @@ export class NekoConnection extends EventEmitter<NekoConnectionEvents> {
|
|||
}
|
||||
|
||||
this._webrtcConnect(video)
|
||||
|
||||
this._shouldReconnect = true
|
||||
}
|
||||
|
||||
public disconnect() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue