]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/videos/+video-watch/video-watch.component.ts
See commit 2a97572 fix #397 (regression)
[github/Chocobozzz/PeerTube.git] / client / src / app / videos / +video-watch / video-watch.component.ts
index b3ebe3e4b46ca0e01b12bab9d88ea98aa1bf8e84..182703cdf4d5169537f5951adb0c7b0f8e86ea3c 100644 (file)
@@ -1,4 +1,4 @@
-import { Component, ElementRef, NgZone, OnDestroy, OnInit, ViewChild, OnChanges } from '@angular/core'
+import { Component, ElementRef, NgZone, OnDestroy, OnInit, ViewChild } from '@angular/core'
 import { ActivatedRoute, Router } from '@angular/router'
 import { RedirectService } from '@app/core/routing/redirect.service'
 import { peertubeLocalStorage } from '@app/shared/misc/peertube-local-storage'
@@ -9,20 +9,18 @@ import { Subscription } from 'rxjs/Subscription'
 import * as videojs from 'video.js'
 import 'videojs-hotkeys'
 import * as WebTorrent from 'webtorrent'
-import { UserVideoRateType, VideoRateType, FeedFormat } from '../../../../../shared'
+import { UserVideoRateType, VideoRateType } from '../../../../../shared'
 import '../../../assets/player/peertube-videojs-plugin'
 import { AuthService, ConfirmService } from '../../core'
 import { VideoBlacklistService } from '../../shared'
 import { Account } from '../../shared/account/account.model'
 import { VideoDetails } from '../../shared/video/video-details.model'
-import { VideoFeedComponent } from '../../shared/video/video-feed.component'
 import { Video } from '../../shared/video/video.model'
 import { VideoService } from '../../shared/video/video.service'
 import { MarkdownService } from '../shared'
 import { VideoDownloadComponent } from './modal/video-download.component'
 import { VideoReportComponent } from './modal/video-report.component'
 import { VideoShareComponent } from './modal/video-share.component'
-import { environment } from '../../../environments/environment'
 import { getVideojsOptions } from '../../../assets/player/peertube-player'
 
 @Component({
@@ -248,13 +246,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
   }
 
   generateSyndicationList () {
-    const feeds = this.videoService.getAccountFeed(
-      this.video.account.id,
-      (this.video.isLocal) ? environment.apiUrl : this.video.account.host
-    )
-    this.syndicationItems['rss 2.0'] = feeds[FeedFormat.RSS]
-    this.syndicationItems['atom 1.0'] = feeds[FeedFormat.ATOM]
-    this.syndicationItems['json 1.0'] = feeds[FeedFormat.JSON]
+    this.syndicationItems = this.videoService.getAccountFeedUrls(this.video.account.id)
   }
 
   isVideoRemovable () {