aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app')
-rw-r--r--client/src/app/+accounts/account-videos/account-videos.component.ts13
-rw-r--r--client/src/app/+video-channels/video-channel-videos/video-channel-videos.component.ts13
-rw-r--r--client/src/app/app.component.ts4
3 files changed, 16 insertions, 14 deletions
diff --git a/client/src/app/+accounts/account-videos/account-videos.component.ts b/client/src/app/+accounts/account-videos/account-videos.component.ts
index 1814ef455..0d579fa0c 100644
--- a/client/src/app/+accounts/account-videos/account-videos.component.ts
+++ b/client/src/app/+accounts/account-videos/account-videos.component.ts
@@ -7,7 +7,7 @@ import { AbstractVideoList } from '../../shared/video/abstract-video-list'
7import { VideoService } from '../../shared/video/video.service' 7import { VideoService } from '../../shared/video/video.service'
8import { Account } from '@app/shared/account/account.model' 8import { Account } from '@app/shared/account/account.model'
9import { AccountService } from '@app/shared/account/account.service' 9import { AccountService } from '@app/shared/account/account.service'
10import { tap } from 'rxjs/operators' 10import { first, tap } from 'rxjs/operators'
11import { I18n } from '@ngx-translate/i18n-polyfill' 11import { I18n } from '@ngx-translate/i18n-polyfill'
12import { Subscription } from 'rxjs' 12import { Subscription } from 'rxjs'
13import { ScreenService } from '@app/shared/misc/screen.service' 13import { ScreenService } from '@app/shared/misc/screen.service'
@@ -50,12 +50,13 @@ export class AccountVideosComponent extends AbstractVideoList implements OnInit,
50 50
51 // Parent get the account for us 51 // Parent get the account for us
52 this.accountSub = this.accountService.accountLoaded 52 this.accountSub = this.accountService.accountLoaded
53 .subscribe(account => { 53 .pipe(first())
54 this.account = account 54 .subscribe(account => {
55 this.account = account
55 56
56 this.reloadVideos() 57 this.reloadVideos()
57 this.generateSyndicationList() 58 this.generateSyndicationList()
58 }) 59 })
59 } 60 }
60 61
61 ngOnDestroy () { 62 ngOnDestroy () {
diff --git a/client/src/app/+video-channels/video-channel-videos/video-channel-videos.component.ts b/client/src/app/+video-channels/video-channel-videos/video-channel-videos.component.ts
index 2045a095d..5e60b34b4 100644
--- a/client/src/app/+video-channels/video-channel-videos/video-channel-videos.component.ts
+++ b/client/src/app/+video-channels/video-channel-videos/video-channel-videos.component.ts
@@ -7,7 +7,7 @@ import { AbstractVideoList } from '../../shared/video/abstract-video-list'
7import { VideoService } from '../../shared/video/video.service' 7import { VideoService } from '../../shared/video/video.service'
8import { VideoChannelService } from '@app/shared/video-channel/video-channel.service' 8import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
9import { VideoChannel } from '@app/shared/video-channel/video-channel.model' 9import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
10import { tap } from 'rxjs/operators' 10import { first, tap } from 'rxjs/operators'
11import { I18n } from '@ngx-translate/i18n-polyfill' 11import { I18n } from '@ngx-translate/i18n-polyfill'
12import { Subscription } from 'rxjs' 12import { Subscription } from 'rxjs'
13import { ScreenService } from '@app/shared/misc/screen.service' 13import { ScreenService } from '@app/shared/misc/screen.service'
@@ -50,12 +50,13 @@ export class VideoChannelVideosComponent extends AbstractVideoList implements On
50 50
51 // Parent get the video channel for us 51 // Parent get the video channel for us
52 this.videoChannelSub = this.videoChannelService.videoChannelLoaded 52 this.videoChannelSub = this.videoChannelService.videoChannelLoaded
53 .subscribe(videoChannel => { 53 .pipe(first())
54 this.videoChannel = videoChannel 54 .subscribe(videoChannel => {
55 this.videoChannel = videoChannel
55 56
56 this.reloadVideos() 57 this.reloadVideos()
57 this.generateSyndicationList() 58 this.generateSyndicationList()
58 }) 59 })
59 } 60 }
60 61
61 ngOnDestroy () { 62 ngOnDestroy () {
diff --git a/client/src/app/app.component.ts b/client/src/app/app.component.ts
index ad0588b99..915466af7 100644
--- a/client/src/app/app.component.ts
+++ b/client/src/app/app.component.ts
@@ -125,8 +125,8 @@ export class AppComponent implements OnInit {
125 try { 125 try {
126 resetScroll = false 126 resetScroll = false
127 127
128 const previousUrl = new URL(window.location.origin + e1.url) 128 const previousUrl = new URL(window.location.origin + e1.urlAfterRedirects)
129 const nextUrl = new URL(window.location.origin + e2.url) 129 const nextUrl = new URL(window.location.origin + e2.urlAfterRedirects)
130 130
131 if (previousUrl.pathname !== nextUrl.pathname) { 131 if (previousUrl.pathname !== nextUrl.pathname) {
132 resetScroll = true 132 resetScroll = true