From b3d92510157f9066ea7fa82c303bea7a10eb55b6 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 21 Oct 2016 11:33:31 +0200 Subject: Server: Uploads -> Videos --- server/models/video.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'server/models/video.js') diff --git a/server/models/video.js b/server/models/video.js index 1feefe24f..05c4f51cb 100644 --- a/server/models/video.js +++ b/server/models/video.js @@ -94,7 +94,7 @@ VideoSchema.pre('save', function (next) { const tasks = [] if (video.isOwned()) { - const videoPath = pathUtils.join(constants.CONFIG.STORAGE.UPLOAD_DIR, video.filename) + const videoPath = pathUtils.join(constants.CONFIG.STORAGE.VIDEOS_DIR, video.filename) this.podUrl = constants.CONFIG.WEBSERVER.URL tasks.push( @@ -258,7 +258,7 @@ function removeThumbnail (video, callback) { } function removeFile (video, callback) { - fs.unlink(constants.CONFIG.STORAGE.UPLOAD_DIR + video.filename, callback) + fs.unlink(constants.CONFIG.STORAGE.VIDEOS_DIR + video.filename, callback) } // Maybe the torrent is not seeded, but we catch the error to don't stop the removing process -- cgit v1.2.3