diff options
author | Chocobozzz <me@florianbigard.com> | 2022-06-27 10:36:16 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2022-06-27 10:36:16 +0200 |
commit | 41e74ec9cd6076109c91128047d8b866c36a3005 (patch) | |
tree | c70c6c00913f42c19064e24cd725ded83f71a70a /server/controllers/feeds.ts | |
parent | 7a5c3d77fedd9099d1711feecfa975856750bcdf (diff) | |
download | PeerTube-41e74ec9cd6076109c91128047d8b866c36a3005.tar.gz PeerTube-41e74ec9cd6076109c91128047d8b866c36a3005.tar.zst PeerTube-41e74ec9cd6076109c91128047d8b866c36a3005.zip |
Fix broken feeds with published live
Diffstat (limited to 'server/controllers/feeds.ts')
-rw-r--r-- | server/controllers/feeds.ts | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/server/controllers/feeds.ts b/server/controllers/feeds.ts index c929a6726..ad93d700f 100644 --- a/server/controllers/feeds.ts +++ b/server/controllers/feeds.ts | |||
@@ -312,11 +312,13 @@ function addVideosToFeed (feed: Feed, videos: VideoModel[]) { | |||
312 | torrents, | 312 | torrents, |
313 | 313 | ||
314 | // Enclosure | 314 | // Enclosure |
315 | video: { | 315 | video: videoFiles.length !== 0 |
316 | url: videoFiles[0].url, | 316 | ? { |
317 | length: videoFiles[0].fileSize, | 317 | url: videoFiles[0].url, |
318 | type: videoFiles[0].type | 318 | length: videoFiles[0].fileSize, |
319 | }, | 319 | type: videoFiles[0].type |
320 | } | ||
321 | : undefined, | ||
320 | 322 | ||
321 | // Media RSS | 323 | // Media RSS |
322 | videos: videoFiles, | 324 | videos: videoFiles, |