aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/account
diff options
context:
space:
mode:
Diffstat (limited to 'server/models/account')
-rw-r--r--server/models/account/user.ts7
1 files changed, 7 insertions, 0 deletions
diff --git a/server/models/account/user.ts b/server/models/account/user.ts
index 1b1fc5ee8..ea6d63312 100644
--- a/server/models/account/user.ts
+++ b/server/models/account/user.ts
@@ -21,6 +21,7 @@ import { hasUserRight, USER_ROLE_LABELS, UserRight } from '../../../shared'
21import { User, UserRole } from '../../../shared/models/users' 21import { User, UserRole } from '../../../shared/models/users'
22import { 22import {
23 isUserAutoPlayVideoValid, 23 isUserAutoPlayVideoValid,
24 isUserBlockedValid,
24 isUserNSFWPolicyValid, 25 isUserNSFWPolicyValid,
25 isUserPasswordValid, 26 isUserPasswordValid,
26 isUserRoleValid, 27 isUserRoleValid,
@@ -101,6 +102,12 @@ export class UserModel extends Model<UserModel> {
101 autoPlayVideo: boolean 102 autoPlayVideo: boolean
102 103
103 @AllowNull(false) 104 @AllowNull(false)
105 @Default(false)
106 @Is('UserBlocked', value => throwIfNotValid(value, isUserBlockedValid, 'blocked boolean'))
107 @Column
108 blocked: boolean
109
110 @AllowNull(false)
104 @Is('UserRole', value => throwIfNotValid(value, isUserRoleValid, 'role')) 111 @Is('UserRole', value => throwIfNotValid(value, isUserRoleValid, 'role'))
105 @Column 112 @Column
106 role: number 113 role: number