mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-19 02:56:23 +08:00
refactor(editor): should not rely on doc collection type (#9501)
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
import type { Collection } from '@affine/env/filter';
|
||||
import type { DocCollection } from '@blocksuite/affine/store';
|
||||
import type { Workspace } from '@blocksuite/affine/store';
|
||||
import { nanoid } from 'nanoid';
|
||||
import type { Map as YMap } from 'yjs';
|
||||
import { Doc as YDoc } from 'yjs';
|
||||
export class UserSetting {
|
||||
constructor(
|
||||
private readonly docCollection: DocCollection,
|
||||
private readonly docCollection: Workspace,
|
||||
private readonly userId: string
|
||||
) {}
|
||||
|
||||
@@ -38,9 +38,6 @@ export class UserSetting {
|
||||
}
|
||||
}
|
||||
|
||||
export const getUserSetting = (
|
||||
docCollection: DocCollection,
|
||||
userId: string
|
||||
) => {
|
||||
export const getUserSetting = (docCollection: Workspace, userId: string) => {
|
||||
return new UserSetting(docCollection, userId);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user