mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-22 12:36:24 +08:00
fix(core): disconnect ws when user logout (#8188)
This commit is contained in:
@@ -70,5 +70,7 @@ export class WorkspaceEngine extends Entity<{
|
||||
|
||||
override dispose(): void {
|
||||
this.forceStop();
|
||||
this.doc.dispose();
|
||||
this.awareness.dispose();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,4 +16,10 @@ export class WorkspaceEngineService extends Service {
|
||||
constructor(private readonly workspaceScope: WorkspaceScope) {
|
||||
super();
|
||||
}
|
||||
|
||||
override dispose(): void {
|
||||
this._engine?.dispose();
|
||||
this._engine = null;
|
||||
super.dispose();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user