From 312644ce3a59fcc10cc08d422081ebacfa14eec7 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 4 Dec 2020 09:24:14 +0100 Subject: Add badge for permanent live in live info modal --- .../shared-video-live/live-stream-information.component.ts | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'client/src/app/shared/shared-video-live/live-stream-information.component.ts') diff --git a/client/src/app/shared/shared-video-live/live-stream-information.component.ts b/client/src/app/shared/shared-video-live/live-stream-information.component.ts index e6142eb2e..9a5d2809b 100644 --- a/client/src/app/shared/shared-video-live/live-stream-information.component.ts +++ b/client/src/app/shared/shared-video-live/live-stream-information.component.ts @@ -1,6 +1,7 @@ import { Component, ElementRef, ViewChild } from '@angular/core' import { Video } from '@app/shared/shared-main' import { NgbModal } from '@ng-bootstrap/ng-bootstrap' +import { LiveVideo } from '@shared/models' import { LiveVideoService } from './live-video.service' @Component({ @@ -12,8 +13,7 @@ export class LiveStreamInformationComponent { @ViewChild('modal', { static: true }) modal: ElementRef video: Video - rtmpUrl = '' - streamKey = '' + live: LiveVideo constructor ( private modalService: NgbModal, @@ -22,8 +22,7 @@ export class LiveStreamInformationComponent { show (video: Video) { this.video = video - this.rtmpUrl = '' - this.streamKey = '' + this.live = undefined this.loadLiveInfo(video) @@ -33,9 +32,6 @@ export class LiveStreamInformationComponent { private loadLiveInfo (video: Video) { this.liveVideoService.getVideoLive(video.id) - .subscribe(live => { - this.rtmpUrl = live.rtmpUrl - this.streamKey = live.streamKey - }) + .subscribe(live => this.live = live) } } -- cgit v1.2.3