diff options
Diffstat (limited to 'client/src/app/shared/video/video-details.model.ts')
-rw-r--r-- | client/src/app/shared/video/video-details.model.ts | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/client/src/app/shared/video/video-details.model.ts b/client/src/app/shared/video/video-details.model.ts index 388357343..8463e15d7 100644 --- a/client/src/app/shared/video/video-details.model.ts +++ b/client/src/app/shared/video/video-details.model.ts | |||
@@ -44,22 +44,6 @@ export class VideoDetails extends Video implements VideoDetailsServerModel { | |||
44 | this.buildLikeAndDislikePercents() | 44 | this.buildLikeAndDislikePercents() |
45 | } | 45 | } |
46 | 46 | ||
47 | isRemovableBy (user: AuthUser) { | ||
48 | return user && this.isLocal === true && (this.account.name === user.username || user.hasRight(UserRight.REMOVE_ANY_VIDEO)) | ||
49 | } | ||
50 | |||
51 | isBlackistableBy (user: AuthUser) { | ||
52 | return this.blacklisted !== true && user && user.hasRight(UserRight.MANAGE_VIDEO_BLACKLIST) === true | ||
53 | } | ||
54 | |||
55 | isUnblacklistableBy (user: AuthUser) { | ||
56 | return this.blacklisted === true && user && user.hasRight(UserRight.MANAGE_VIDEO_BLACKLIST) === true | ||
57 | } | ||
58 | |||
59 | isUpdatableBy (user: AuthUser) { | ||
60 | return user && this.isLocal === true && (this.account.name === user.username || user.hasRight(UserRight.UPDATE_ANY_VIDEO)) | ||
61 | } | ||
62 | |||
63 | buildLikeAndDislikePercents () { | 47 | buildLikeAndDislikePercents () { |
64 | this.likesPercent = (this.likes / (this.likes + this.dislikes)) * 100 | 48 | this.likesPercent = (this.likes / (this.likes + this.dislikes)) * 100 |
65 | this.dislikesPercent = (this.dislikes / (this.likes + this.dislikes)) * 100 | 49 | this.dislikesPercent = (this.dislikes / (this.likes + this.dislikes)) * 100 |