Update more API endpoints to use new user model

This commit is contained in:
advplyr 2024-08-11 15:15:34 -05:00
parent 9facf77ff1
commit afc16358ca
23 changed files with 856 additions and 404 deletions

View file

@ -419,8 +419,11 @@ class User extends Model {
)
}
get isRoot() {
return this.type === 'root'
}
get isAdminOrUp() {
return this.type === 'root' || this.type === 'admin'
return this.isRoot || this.type === 'admin'
}
get isUser() {
return this.type === 'user'