diff options
Diffstat (limited to 'client/src/app/shared/shared-video-miniature/video-filters-header.component.ts')
-rw-r--r-- | client/src/app/shared/shared-video-miniature/video-filters-header.component.ts | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/client/src/app/shared/shared-video-miniature/video-filters-header.component.ts b/client/src/app/shared/shared-video-miniature/video-filters-header.component.ts index 2c52e43f7..7b806248b 100644 --- a/client/src/app/shared/shared-video-miniature/video-filters-header.component.ts +++ b/client/src/app/shared/shared-video-miniature/video-filters-header.component.ts | |||
@@ -72,15 +72,10 @@ export class VideoFiltersHeaderComponent implements OnInit, OnDestroy { | |||
72 | return this.auth.getUser().hasRight(UserRight.SEE_ALL_VIDEOS) | 72 | return this.auth.getUser().hasRight(UserRight.SEE_ALL_VIDEOS) |
73 | } | 73 | } |
74 | 74 | ||
75 | isTrendingSortEnabled (sort: 'most-viewed' | 'hot' | 'best' | 'most-liked') { | 75 | isTrendingSortEnabled (sort: 'most-viewed' | 'hot' | 'most-liked') { |
76 | const serverConfig = this.serverService.getHTMLConfig() | 76 | const serverConfig = this.serverService.getHTMLConfig() |
77 | 77 | ||
78 | const enabled = serverConfig.trending.videos.algorithms.enabled.includes(sort) | 78 | return serverConfig.trending.videos.algorithms.enabled.includes(sort) |
79 | |||
80 | // Best is adapted from the user | ||
81 | if (sort === 'best') return enabled && this.auth.isLoggedIn() | ||
82 | |||
83 | return enabled | ||
84 | } | 79 | } |
85 | 80 | ||
86 | resetFilter (key: string, canRemove: boolean) { | 81 | resetFilter (key: string, canRemove: boolean) { |