diff options
Diffstat (limited to 'server/models/account/account.ts')
-rw-r--r-- | server/models/account/account.ts | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/server/models/account/account.ts b/server/models/account/account.ts index bf2ed0a61..c53312990 100644 --- a/server/models/account/account.ts +++ b/server/models/account/account.ts | |||
@@ -33,15 +33,15 @@ export enum ScopeNames { | |||
33 | SUMMARY = 'SUMMARY' | 33 | SUMMARY = 'SUMMARY' |
34 | } | 34 | } |
35 | 35 | ||
36 | @DefaultScope({ | 36 | @DefaultScope(() => ({ |
37 | include: [ | 37 | include: [ |
38 | { | 38 | { |
39 | model: () => ActorModel, // Default scope includes avatar and server | 39 | model: ActorModel, // Default scope includes avatar and server |
40 | required: true | 40 | required: true |
41 | } | 41 | } |
42 | ] | 42 | ] |
43 | }) | 43 | })) |
44 | @Scopes({ | 44 | @Scopes(() => ({ |
45 | [ ScopeNames.SUMMARY ]: (whereActor?: WhereOptions) => { | 45 | [ ScopeNames.SUMMARY ]: (whereActor?: WhereOptions) => { |
46 | return { | 46 | return { |
47 | attributes: [ 'id', 'name' ], | 47 | attributes: [ 'id', 'name' ], |
@@ -66,7 +66,7 @@ export enum ScopeNames { | |||
66 | ] | 66 | ] |
67 | } | 67 | } |
68 | } | 68 | } |
69 | }) | 69 | })) |
70 | @Table({ | 70 | @Table({ |
71 | tableName: 'account', | 71 | tableName: 'account', |
72 | indexes: [ | 72 | indexes: [ |