From b31d72625dd32143a45277528b90bb67a881f249 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 5 May 2021 15:26:28 +0200 Subject: Plugin user.getAuthUser is now async So we can load the full user --- server/models/account/user.ts | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'server/models/account/user.ts') diff --git a/server/models/account/user.ts b/server/models/account/user.ts index 00c6d73aa..513455773 100644 --- a/server/models/account/user.ts +++ b/server/models/account/user.ts @@ -565,6 +565,10 @@ export class UserModel extends Model { return UserModel.unscoped().findByPk(id) } + static loadByIdFull (id: number): Promise { + return UserModel.findByPk(id) + } + static loadByIdWithChannels (id: number, withStats = false): Promise { const scopes = [ ScopeNames.WITH_VIDEOCHANNELS -- cgit v1.2.3