From d59cfc32d54439644d0ed8af27b73bd552cec387 Mon Sep 17 00:00:00 2001 From: yadhap Dahal Date: Fri, 7 May 2021 09:04:42 -0400 Subject: [PATCH] Fixed error Cannot set headers after they are sent to the client --- server/routes/user/read.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/routes/user/read.js b/server/routes/user/read.js index 259ec26a3..b9d60bdee 100644 --- a/server/routes/user/read.js +++ b/server/routes/user/read.js @@ -139,7 +139,8 @@ router.post('/forgot-password', [ res.status(response.statusCode).json(response.message); }) .catch((err) => { - res.status(500).json({ errors: [err.error] }); + // res.status(500).json({ errors: [err.error] }); + console.log(err); }) })