diff options
author | kimsible <kimsible@users.noreply.github.com> | 2020-08-07 23:24:22 +0200 |
---|---|---|
committer | Chocobozzz <chocobozzz@cpy.re> | 2020-08-14 15:03:38 +0200 |
commit | ddb0303f4da8777b0c1254eada8b2cd12774b716 (patch) | |
tree | 0048e5c2887d5f43d697829b2360648f2551fbd7 /client/src/app/+videos/+video-watch/comment/video-comment.component.ts | |
parent | 3c176894bae9de7958605fe432bff770b9232807 (diff) | |
download | PeerTube-ddb0303f4da8777b0c1254eada8b2cd12774b716.tar.gz PeerTube-ddb0303f4da8777b0c1254eada8b2cd12774b716.tar.zst PeerTube-ddb0303f4da8777b0c1254eada8b2cd12774b716.zip |
Fix i18n on delete modal and linter
Diffstat (limited to 'client/src/app/+videos/+video-watch/comment/video-comment.component.ts')
-rw-r--r-- | client/src/app/+videos/+video-watch/comment/video-comment.component.ts | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/client/src/app/+videos/+video-watch/comment/video-comment.component.ts b/client/src/app/+videos/+video-watch/comment/video-comment.component.ts index 8473350be..fe069b54c 100644 --- a/client/src/app/+videos/+video-watch/comment/video-comment.component.ts +++ b/client/src/app/+videos/+video-watch/comment/video-comment.component.ts | |||
@@ -112,11 +112,21 @@ export class VideoCommentComponent implements OnInit, OnChanges { | |||
112 | } | 112 | } |
113 | 113 | ||
114 | isRedraftableByUser () { | 114 | isRedraftableByUser () { |
115 | return this.comment.account && this.isUserLoggedIn() && this.user.account.id === this.comment.account.id && this.comment.totalReplies === 0 | 115 | return ( |
116 | } | 116 | this.comment.account && |
117 | 117 | this.isUserLoggedIn() && | |
118 | isReportableByUser() { | 118 | this.user.account.id === this.comment.account.id && |
119 | return this.comment.account && this.isUserLoggedIn() && this.comment.isDeleted === false && this.authService.getUser().account.id !== this.comment.account.id | 119 | this.comment.totalReplies === 0 |
120 | ) | ||
121 | } | ||
122 | |||
123 | isReportableByUser () { | ||
124 | return ( | ||
125 | this.comment.account && | ||
126 | this.isUserLoggedIn() && | ||
127 | this.comment.isDeleted === false && | ||
128 | this.authService.getUser().account.id !== this.comment.account.id | ||
129 | ) | ||
120 | } | 130 | } |
121 | 131 | ||
122 | switchToDefaultAvatar ($event: Event) { | 132 | switchToDefaultAvatar ($event: Event) { |