diff options
author | Gérald Niel <gerald.niel@gegeweb.org> | 2018-04-19 19:28:55 +0200 |
---|---|---|
committer | Gérald Niel <gerald.niel@gegeweb.org> | 2018-04-19 19:28:55 +0200 |
commit | 0db1a226507a39b0a663e3e63f04851836a44d5a (patch) | |
tree | 8c8dad658ea5608afaae238cfb6fe803292f908f /client/src/app/shared/users | |
parent | 0030284b0df2983914291d6fe83675e2aa892e6a (diff) | |
parent | d4f3fea659163749f9ea879a5e1dd313106353c6 (diff) | |
download | PeerTube-0db1a226507a39b0a663e3e63f04851836a44d5a.tar.gz PeerTube-0db1a226507a39b0a663e3e63f04851836a44d5a.tar.zst PeerTube-0db1a226507a39b0a663e3e63f04851836a44d5a.zip |
Merge branch 'develop' of framagit.org:chocobozzz/PeerTube into develop
Diffstat (limited to 'client/src/app/shared/users')
-rw-r--r-- | client/src/app/shared/users/user.model.ts | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/client/src/app/shared/users/user.model.ts b/client/src/app/shared/users/user.model.ts index 4a94b032d..2bdc48a1d 100644 --- a/client/src/app/shared/users/user.model.ts +++ b/client/src/app/shared/users/user.model.ts | |||
@@ -1,5 +1,6 @@ | |||
1 | import { hasUserRight, User as UserServerModel, UserRight, UserRole, VideoChannel } from '../../../../../shared' | 1 | import { hasUserRight, User as UserServerModel, UserRight, UserRole, VideoChannel } from '../../../../../shared' |
2 | import { Account } from '../account/account.model' | 2 | import { Account } from '../account/account.model' |
3 | import { NSFWPolicyType } from '../../../../../shared/models/videos/nsfw-policy.type' | ||
3 | 4 | ||
4 | export type UserConstructorHash = { | 5 | export type UserConstructorHash = { |
5 | id: number, | 6 | id: number, |
@@ -7,7 +8,7 @@ export type UserConstructorHash = { | |||
7 | email: string, | 8 | email: string, |
8 | role: UserRole, | 9 | role: UserRole, |
9 | videoQuota?: number, | 10 | videoQuota?: number, |
10 | displayNSFW?: boolean, | 11 | nsfwPolicy?: NSFWPolicyType, |
11 | autoPlayVideo?: boolean, | 12 | autoPlayVideo?: boolean, |
12 | createdAt?: Date, | 13 | createdAt?: Date, |
13 | account?: Account, | 14 | account?: Account, |
@@ -18,7 +19,7 @@ export class User implements UserServerModel { | |||
18 | username: string | 19 | username: string |
19 | email: string | 20 | email: string |
20 | role: UserRole | 21 | role: UserRole |
21 | displayNSFW: boolean | 22 | nsfwPolicy: NSFWPolicyType |
22 | autoPlayVideo: boolean | 23 | autoPlayVideo: boolean |
23 | videoQuota: number | 24 | videoQuota: number |
24 | account: Account | 25 | account: Account |
@@ -40,8 +41,8 @@ export class User implements UserServerModel { | |||
40 | this.videoQuota = hash.videoQuota | 41 | this.videoQuota = hash.videoQuota |
41 | } | 42 | } |
42 | 43 | ||
43 | if (hash.displayNSFW !== undefined) { | 44 | if (hash.nsfwPolicy !== undefined) { |
44 | this.displayNSFW = hash.displayNSFW | 45 | this.nsfwPolicy = hash.nsfwPolicy |
45 | } | 46 | } |
46 | 47 | ||
47 | if (hash.autoPlayVideo !== undefined) { | 48 | if (hash.autoPlayVideo !== undefined) { |