mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 19:42:24 +02:00
don't notify prior to scheduled update
also increase timeouts on user-notification test
This commit is contained in:
parent
552dd3306f
commit
f7effe8dc7
2 changed files with 44 additions and 4 deletions
|
@ -91,7 +91,8 @@ async function onVideoFileTranscoderOrImportSuccess (video: VideoModel) {
|
|||
return { videoDatabase, videoPublished }
|
||||
})
|
||||
|
||||
if (videoPublished) {
|
||||
// don't notify prior to scheduled video update
|
||||
if (videoPublished && !videoDatabase.ScheduleVideoUpdate) {
|
||||
Notifier.Instance.notifyOnNewVideo(videoDatabase)
|
||||
Notifier.Instance.notifyOnPendingVideoPublished(videoDatabase)
|
||||
}
|
||||
|
@ -149,8 +150,11 @@ async function onVideoFileOptimizerSuccess (videoArg: VideoModel, isNewVideo: bo
|
|||
return { videoDatabase, videoPublished }
|
||||
})
|
||||
|
||||
if (isNewVideo) Notifier.Instance.notifyOnNewVideo(videoDatabase)
|
||||
if (videoPublished) Notifier.Instance.notifyOnPendingVideoPublished(videoDatabase)
|
||||
// don't notify prior to scheduled video update
|
||||
if (!videoDatabase.ScheduleVideoUpdate) {
|
||||
if (isNewVideo) Notifier.Instance.notifyOnNewVideo(videoDatabase)
|
||||
if (videoPublished) Notifier.Instance.notifyOnPendingVideoPublished(videoDatabase)
|
||||
}
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue