Fix privacy error on live update without privacy
This commit is contained in:
parent
af8a47125f
commit
4662badde7
1 changed files with 1 additions and 1 deletions
|
@ -231,7 +231,7 @@ const videosUpdateValidator = getCommonVideoEditAttributes().concat([
|
|||
if (!isValidPasswordProtectedPrivacy(req, res)) return cleanUpReqFiles(req)
|
||||
|
||||
const video = getVideoWithAttributes(res)
|
||||
if (video.isLive && video.privacy !== req.body.privacy && video.state !== VideoState.WAITING_FOR_LIVE) {
|
||||
if (exists(req.body.privacy) && video.isLive && video.privacy !== req.body.privacy && video.state !== VideoState.WAITING_FOR_LIVE) {
|
||||
return res.fail({ message: 'Cannot update privacy of a live that has already started' })
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue