]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/videos/video-list/video-trending.component.ts
Trending by interval
[github/Chocobozzz/PeerTube.git] / client / src / app / videos / video-list / video-trending.component.ts
index f2174aa145cb4daa1a08ada098fd75ad3764c444..8f3d3842b494a31c74e6de679ee8c3159b5fb918 100644 (file)
@@ -18,7 +18,7 @@ import { ScreenService } from '@app/shared/misc/screen.service'
 export class VideoTrendingComponent extends AbstractVideoList implements OnInit, OnDestroy {
   titlePage: string
   currentRoute = '/videos/trending'
-  defaultSort: VideoSortField = '-views'
+  defaultSort: VideoSortField = '-trending'
 
   constructor (
     protected router: Router,
@@ -47,10 +47,10 @@ export class VideoTrendingComponent extends AbstractVideoList implements OnInit,
 
   getVideosObservable (page: number) {
     const newPagination = immutableAssign(this.pagination, { currentPage: page })
-    return this.videoService.getVideos(newPagination, this.sort)
+    return this.videoService.getVideos(newPagination, this.sort, undefined, this.categoryOneOf)
   }
 
   generateSyndicationList () {
-    this.syndicationItems = this.videoService.getVideoFeedUrls(this.sort)
+    this.syndicationItems = this.videoService.getVideoFeedUrls(this.sort, undefined, this.categoryOneOf)
   }
 }