diff options
author | Chocobozzz <me@florianbigard.com> | 2019-09-04 15:03:50 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-09-04 15:03:50 +0200 |
commit | dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6 (patch) | |
tree | 0a6a54143e1312eddf269ac65b7a4ace9948eecc /client/src/app/shared/video | |
parent | f8278b96053d42ac46aea17f949325caa03e8a00 (diff) | |
download | PeerTube-dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6.tar.gz PeerTube-dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6.tar.zst PeerTube-dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6.zip |
Fix auto blacklist view
Diffstat (limited to 'client/src/app/shared/video')
-rw-r--r-- | client/src/app/shared/video/video-miniature.component.html | 2 | ||||
-rw-r--r-- | client/src/app/shared/video/video-miniature.component.ts | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/client/src/app/shared/video/video-miniature.component.html b/client/src/app/shared/video/video-miniature.component.html index 51ca1393d..5d5691b75 100644 --- a/client/src/app/shared/video/video-miniature.component.html +++ b/client/src/app/shared/video/video-miniature.component.html | |||
@@ -31,7 +31,7 @@ | |||
31 | 31 | ||
32 | <div class="video-info-privacy"> | 32 | <div class="video-info-privacy"> |
33 | <ng-container *ngIf="displayOptions.privacyText">{{ video.privacy.label }}</ng-container> | 33 | <ng-container *ngIf="displayOptions.privacyText">{{ video.privacy.label }}</ng-container> |
34 | <ng-container *ngIf="displayOptions.privacyText && getStateLabel(video)"> - </ng-container> | 34 | <ng-container *ngIf="displayOptions.privacyText && displayOptions.state && getStateLabel(video)"> - </ng-container> |
35 | <ng-container *ngIf="displayOptions.state">{{ getStateLabel(video) }}</ng-container> | 35 | <ng-container *ngIf="displayOptions.state">{{ getStateLabel(video) }}</ng-container> |
36 | </div> | 36 | </div> |
37 | 37 | ||
diff --git a/client/src/app/shared/video/video-miniature.component.ts b/client/src/app/shared/video/video-miniature.component.ts index 48475033c..d5c7dfd9b 100644 --- a/client/src/app/shared/video/video-miniature.component.ts +++ b/client/src/app/shared/video/video-miniature.component.ts | |||
@@ -95,6 +95,8 @@ export class VideoMiniatureComponent implements OnInit { | |||
95 | } | 95 | } |
96 | 96 | ||
97 | getStateLabel (video: Video) { | 97 | getStateLabel (video: Video) { |
98 | if (!video.state) return '' | ||
99 | |||
98 | if (video.privacy.id !== VideoPrivacy.PRIVATE && video.state.id === VideoState.PUBLISHED) { | 100 | if (video.privacy.id !== VideoPrivacy.PRIVATE && video.state.id === VideoState.PUBLISHED) { |
99 | return this.i18n('Published') | 101 | return this.i18n('Published') |
100 | } | 102 | } |