aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/shared/video-blacklist
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-09-04 15:03:50 +0200
committerChocobozzz <me@florianbigard.com>2019-09-04 15:03:50 +0200
commitdedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6 (patch)
tree0a6a54143e1312eddf269ac65b7a4ace9948eecc /client/src/app/shared/video-blacklist
parentf8278b96053d42ac46aea17f949325caa03e8a00 (diff)
downloadPeerTube-dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6.tar.gz
PeerTube-dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6.tar.zst
PeerTube-dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6.zip
Fix auto blacklist view
Diffstat (limited to 'client/src/app/shared/video-blacklist')
-rw-r--r--client/src/app/shared/video-blacklist/video-blacklist.service.ts9
1 files changed, 5 insertions, 4 deletions
diff --git a/client/src/app/shared/video-blacklist/video-blacklist.service.ts b/client/src/app/shared/video-blacklist/video-blacklist.service.ts
index a9eab9b6f..d65da85fe 100644
--- a/client/src/app/shared/video-blacklist/video-blacklist.service.ts
+++ b/client/src/app/shared/video-blacklist/video-blacklist.service.ts
@@ -34,7 +34,7 @@ export class VideoBlacklistService {
34 ) 34 )
35 } 35 }
36 36
37 getAutoBlacklistedAsVideoList (videoPagination: ComponentPagination): Observable<{ videos: Video[], totalVideos: number}> { 37 getAutoBlacklistedAsVideoList (videoPagination: ComponentPagination): Observable<ResultList<Video>> {
38 const pagination = this.restService.componentPaginationToRestPagination(videoPagination) 38 const pagination = this.restService.componentPaginationToRestPagination(videoPagination)
39 39
40 // prioritize first created since waiting longest 40 // prioritize first created since waiting longest
@@ -48,9 +48,10 @@ export class VideoBlacklistService {
48 return this.authHttp.get<ResultList<VideoBlacklist>>(VideoBlacklistService.BASE_VIDEOS_URL + 'blacklist', { params }) 48 return this.authHttp.get<ResultList<VideoBlacklist>>(VideoBlacklistService.BASE_VIDEOS_URL + 'blacklist', { params })
49 .pipe( 49 .pipe(
50 map(res => { 50 map(res => {
51 const videos = res.data.map(videoBlacklist => new Video(videoBlacklist.video)) 51 return {
52 const totalVideos = res.total 52 total: res.total,
53 return { videos, totalVideos } 53 data: res.data.map(videoBlacklist => new Video(videoBlacklist.video))
54 }
54 }), 55 }),
55 catchError(res => this.restExtractor.handleError(res)) 56 catchError(res => this.restExtractor.handleError(res))
56 ) 57 )