aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+video-channels
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/+video-channels')
-rw-r--r--client/src/app/+video-channels/video-channels.component.ts6
1 files changed, 5 insertions, 1 deletions
diff --git a/client/src/app/+video-channels/video-channels.component.ts b/client/src/app/+video-channels/video-channels.component.ts
index ea8bda1cf..d2fd265c4 100644
--- a/client/src/app/+video-channels/video-channels.component.ts
+++ b/client/src/app/+video-channels/video-channels.component.ts
@@ -6,6 +6,7 @@ import { ActivatedRoute } from '@angular/router'
6import { AuthService, Notifier, RestExtractor, ScreenService } from '@app/core' 6import { AuthService, Notifier, RestExtractor, ScreenService } from '@app/core'
7import { ListOverflowItem, VideoChannel, VideoChannelService } from '@app/shared/shared-main' 7import { ListOverflowItem, VideoChannel, VideoChannelService } from '@app/shared/shared-main'
8import { SubscribeButtonComponent } from '@app/shared/shared-user-subscription' 8import { SubscribeButtonComponent } from '@app/shared/shared-user-subscription'
9import { HttpStatusCode } from '@shared/core-utils/miscs/http-error-codes'
9 10
10@Component({ 11@Component({
11 templateUrl: './video-channels.component.html', 12 templateUrl: './video-channels.component.html',
@@ -37,7 +38,10 @@ export class VideoChannelsComponent implements OnInit, OnDestroy {
37 map(params => params[ 'videoChannelName' ]), 38 map(params => params[ 'videoChannelName' ]),
38 distinctUntilChanged(), 39 distinctUntilChanged(),
39 switchMap(videoChannelName => this.videoChannelService.getVideoChannel(videoChannelName)), 40 switchMap(videoChannelName => this.videoChannelService.getVideoChannel(videoChannelName)),
40 catchError(err => this.restExtractor.redirectTo404IfNotFound(err, [ 400, 404 ])) 41 catchError(err => this.restExtractor.redirectTo404IfNotFound(err, [
42 HttpStatusCode.BAD_REQUEST_400,
43 HttpStatusCode.NOT_FOUND_404
44 ]))
41 ) 45 )
42 .subscribe(videoChannel => { 46 .subscribe(videoChannel => {
43 this.videoChannel = videoChannel 47 this.videoChannel = videoChannel