aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api/videos/index.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/controllers/api/videos/index.ts')
-rw-r--r--server/controllers/api/videos/index.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/server/controllers/api/videos/index.ts b/server/controllers/api/videos/index.ts
index e70a5319e..815881df3 100644
--- a/server/controllers/api/videos/index.ts
+++ b/server/controllers/api/videos/index.ts
@@ -49,11 +49,11 @@ const videosRouter = express.Router()
49 49
50// multer configuration 50// multer configuration
51const storage = multer.diskStorage({ 51const storage = multer.diskStorage({
52 destination: function (req, file, cb) { 52 destination: (req, file, cb) => {
53 cb(null, CONFIG.STORAGE.VIDEOS_DIR) 53 cb(null, CONFIG.STORAGE.VIDEOS_DIR)
54 }, 54 },
55 55
56 filename: function (req, file, cb) { 56 filename: (req, file, cb) => {
57 let extension = '' 57 let extension = ''
58 if (file.mimetype === 'video/webm') extension = 'webm' 58 if (file.mimetype === 'video/webm') extension = 'webm'
59 else if (file.mimetype === 'video/mp4') extension = 'mp4' 59 else if (file.mimetype === 'video/mp4') extension = 'mp4'
@@ -310,7 +310,7 @@ function updateVideo (req: express.Request, res: express.Response) {
310 // Force fields we want to update 310 // Force fields we want to update
311 // If the transaction is retried, sequelize will think the object has not changed 311 // If the transaction is retried, sequelize will think the object has not changed
312 // So it will skip the SQL request, even if the last one was ROLLBACKed! 312 // So it will skip the SQL request, even if the last one was ROLLBACKed!
313 Object.keys(videoFieldsSave).forEach(function (key) { 313 Object.keys(videoFieldsSave).forEach(key => {
314 const value = videoFieldsSave[key] 314 const value = videoFieldsSave[key]
315 videoInstance.set(key, value) 315 videoInstance.set(key, value)
316 }) 316 })