1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-06 03:50:26 +02:00

Fix live state on user archive import

This commit is contained in:
Chocobozzz 2024-03-12 11:11:53 +01:00
parent 46950fbcc8
commit 0f67adf98a
No known key found for this signature in database
GPG key ID: 583A612D890159BE
2 changed files with 8 additions and 3 deletions

View file

@ -1,4 +1,4 @@
import { LiveVideoLatencyMode, ThumbnailType, VideoExportJSON, VideoPrivacy } from '@peertube/peertube-models'
import { LiveVideoLatencyMode, ThumbnailType, VideoExportJSON, VideoPrivacy, VideoState } from '@peertube/peertube-models'
import { logger, loggerTagsFactory } from '@server/helpers/logger.js'
import { Hooks } from '@server/lib/plugins/hooks.js'
import { buildNextVideoState } from '@server/lib/video-state.js'
@ -207,7 +207,9 @@ export class VideosImporter extends AbstractUserImporter <VideoExportJSON, Impor
videoPasswords: videoImportData.passwords,
duration,
filename: videoImportData.source?.filename,
state: buildNextVideoState()
state: videoImportData.isLive
? VideoState.WAITING_FOR_LIVE
: buildNextVideoState()
},
liveAttributes: videoImportData.live,