From cba3b74593cd12f8bf84dc94982ad628b49ed147 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Garc=C3=ADa=20Aubert?= Date: Mon, 29 Jul 2019 16:27:19 +0200 Subject: [PATCH] Default not needed --- app/middlewares/params.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/middlewares/params.js b/app/middlewares/params.js index 17681e0b..e0d6b01d 100644 --- a/app/middlewares/params.js +++ b/app/middlewares/params.js @@ -7,7 +7,7 @@ module.exports = function params ({ strategy = 'query' } = {}) { const getParams = getParamsFromStrategy(strategy); return function paramsMiddleware (req, res, next) { - const input = Object.assign({}, req.query, req.body || {}); + const input = Object.assign({}, req.query, req.body); try { res.locals.params = getParams(input);