Fix video playlists list
authorChocobozzz <me@florianbigard.com>
Wed, 7 Aug 2019 08:22:21 +0000 (10:22 +0200)
committerChocobozzz <me@florianbigard.com>
Wed, 7 Aug 2019 10:07:59 +0000 (12:07 +0200)
client/src/app/+my-account/my-account-video-playlists/my-account-video-playlists.component.ts

index 0c4e4b0d6223ce13563facdb7a0214db8ac6db4d..76b13fe2b408bd8584734349658ee89106a7b4e2 100644 (file)
@@ -81,10 +81,10 @@ export class MyAccountVideoPlaylistsComponent implements OnInit {
   }
 
   private loadVideoPlaylists () {
-    const playlistsObservable = this.videoPlaylistService.listAccountPlaylists(this.user.account, this.pagination, '-updatedAt')
-
     this.authService.userInformationLoaded
-        .pipe(flatMap(() => playlistsObservable))
+        .pipe(flatMap(() => {
+          return this.videoPlaylistService.listAccountPlaylists(this.user.account, this.pagination, '-updatedAt')
+        }))
         .subscribe(res => {
           this.videoPlaylists = this.videoPlaylists.concat(res.data)
           this.pagination.totalItems = res.total