fix: unbind awareness events before destroying awareness (#2330)

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
Tilman Vatteroth 2022-09-04 21:11:16 +02:00 committed by GitHub
parent 669e73d8a1
commit 4c817e1854
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -35,8 +35,8 @@ export class WebsocketConnection extends WebsocketTransporter {
}
}
this.on('disconnected', () => {
awareness.destroy()
awareness.off('update', updateCallback)
awareness.destroy()
})
this.on('ready', () => {