From 0a59407a3ccfeba30310db51aa927cf6dfb9dfc6 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 6 May 2023 10:24:14 +0900 Subject: [PATCH] fix type --- packages/backend/src/core/entities/UserEntityService.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/backend/src/core/entities/UserEntityService.ts b/packages/backend/src/core/entities/UserEntityService.ts index 562fc5c1e..b822c5dce 100644 --- a/packages/backend/src/core/entities/UserEntityService.ts +++ b/packages/backend/src/core/entities/UserEntityService.ts @@ -292,7 +292,7 @@ export class UserEntityService implements OnModuleInit { public async pack( src: User['id'] | User, - me?: { id: User['id']; isRoot: boolean; } | null | undefined, + me?: { id: User['id']; } | null | undefined, options?: { detail?: D, includeSecrets?: boolean, @@ -308,7 +308,7 @@ export class UserEntityService implements OnModuleInit { const meId = me ? me.id : null; const isMe = meId === user.id; - const iAmModerator = me ? await this.roleService.isModerator(me) : false; + const iAmModerator = me ? await this.roleService.isModerator(me as User) : false; const relation = meId && !isMe && opts.detail ? await this.getRelation(meId, user.id) : null; const pins = opts.detail ? await this.userNotePiningsRepository.createQueryBuilder('pin')