aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2017-10-27 17:27:06 +0200
committerChocobozzz <florian.bigard@gmail.com>2017-10-27 17:27:06 +0200
commit757f0da370a992cf07afd20d3829b2748c76cc15 (patch)
treedf093661b11be5d810e8853712774bf777946609 /client/src
parent954605a804da399317ca62afa2fb9244afa11ebf (diff)
downloadPeerTube-757f0da370a992cf07afd20d3829b2748c76cc15.tar.gz
PeerTube-757f0da370a992cf07afd20d3829b2748c76cc15.tar.zst
PeerTube-757f0da370a992cf07afd20d3829b2748c76cc15.zip
Add tests to user roles
Diffstat (limited to 'client/src')
-rw-r--r--client/src/app/core/auth/auth-user.model.ts2
-rw-r--r--client/src/app/shared/forms/form-validators/user.ts2
2 files changed, 2 insertions, 2 deletions
diff --git a/client/src/app/core/auth/auth-user.model.ts b/client/src/app/core/auth/auth-user.model.ts
index 085b763ec..7b6c8816f 100644
--- a/client/src/app/core/auth/auth-user.model.ts
+++ b/client/src/app/core/auth/auth-user.model.ts
@@ -123,7 +123,7 @@ export class AuthUser extends User {
123 this.tokens.refreshToken = refreshToken 123 this.tokens.refreshToken = refreshToken
124 } 124 }
125 125
126 hasRight(right: UserRight) { 126 hasRight (right: UserRight) {
127 return hasUserRight(this.role, right) 127 return hasUserRight(this.role, right)
128 } 128 }
129 129
diff --git a/client/src/app/shared/forms/form-validators/user.ts b/client/src/app/shared/forms/form-validators/user.ts
index e7473b75b..9d200649c 100644
--- a/client/src/app/shared/forms/form-validators/user.ts
+++ b/client/src/app/shared/forms/form-validators/user.ts
@@ -32,6 +32,6 @@ export const USER_VIDEO_QUOTA = {
32export const USER_ROLE = { 32export const USER_ROLE = {
33 VALIDATORS: [ Validators.required ], 33 VALIDATORS: [ Validators.required ],
34 MESSAGES: { 34 MESSAGES: {
35 'required': 'User role is required.', 35 'required': 'User role is required.'
36 } 36 }
37} 37}