aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api/videos.js
diff options
context:
space:
mode:
Diffstat (limited to 'server/controllers/api/videos.js')
-rw-r--r--server/controllers/api/videos.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/server/controllers/api/videos.js b/server/controllers/api/videos.js
index 4a4c5e162..aeefaa555 100644
--- a/server/controllers/api/videos.js
+++ b/server/controllers/api/videos.js
@@ -444,12 +444,12 @@ function updateVideo (req, res, finalCallback) {
444 transaction: t 444 transaction: t
445 } 445 }
446 446
447 if (videoInfosToUpdate.name) videoInstance.set('name', videoInfosToUpdate.name) 447 if (videoInfosToUpdate.name !== undefined) videoInstance.set('name', videoInfosToUpdate.name)
448 if (videoInfosToUpdate.category) videoInstance.set('category', videoInfosToUpdate.category) 448 if (videoInfosToUpdate.category !== undefined) videoInstance.set('category', videoInfosToUpdate.category)
449 if (videoInfosToUpdate.licence) videoInstance.set('licence', videoInfosToUpdate.licence) 449 if (videoInfosToUpdate.licence !== undefined) videoInstance.set('licence', videoInfosToUpdate.licence)
450 if (videoInfosToUpdate.language) videoInstance.set('language', videoInfosToUpdate.language) 450 if (videoInfosToUpdate.language !== undefined) videoInstance.set('language', videoInfosToUpdate.language)
451 if (videoInfosToUpdate.nsfw) videoInstance.set('nsfw', videoInfosToUpdate.nsfw) 451 if (videoInfosToUpdate.nsfw !== undefined) videoInstance.set('nsfw', videoInfosToUpdate.nsfw)
452 if (videoInfosToUpdate.description) videoInstance.set('description', videoInfosToUpdate.description) 452 if (videoInfosToUpdate.description !== undefined) videoInstance.set('description', videoInfosToUpdate.description)
453 453
454 videoInstance.save(options).asCallback(function (err) { 454 videoInstance.save(options).asCallback(function (err) {
455 return callback(err, t, tagInstances) 455 return callback(err, t, tagInstances)