From 867d005b3492351595f25d59d63805735118d2f7 Mon Sep 17 00:00:00 2001 From: Bobby Wibowo Date: Fri, 29 May 2020 02:56:11 +0700 Subject: [PATCH] Updated uploadController.js Removed unnecessary check. --- controllers/uploadController.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controllers/uploadController.js b/controllers/uploadController.js index 51c352d..bc2c68f 100644 --- a/controllers/uploadController.js +++ b/controllers/uploadController.js @@ -618,7 +618,7 @@ self.storeFilesToDb = async (req, res, user, infoMap) => { await Promise.all(infoMap.map(async info => { // Check if the file exists by checking its hash and size - const dbFile = info.data.hash && await db.table('files') + const dbFile = await db.table('files') .where(function () { if (user === undefined) this.whereNull('userid')