From 9e655e86b185e5347fe157e62c221c64529fc24a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dani=C3=ABl?= Date: Sun, 9 Jun 2024 14:30:27 +0200 Subject: [PATCH] Update file.routes.js --- routes/file.routes.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routes/file.routes.js b/routes/file.routes.js index 8893c0d..08a2cee 100644 --- a/routes/file.routes.js +++ b/routes/file.routes.js @@ -4,7 +4,7 @@ const { uploadFile, getFile } = require("../controllers/file.controller"); const router = express.Router(); const apiKeys = process.env.API_KEYS.split(","); -const allowPublicUploads = process.env.ALLOW_PUBLIC; +const allowPublicUploads = process.env.ALLOW_PUBLIC ?? false; const authenticate = (req, res, next) => { const apiKey = req.headers["x-api-key"] || req.query.api;