From ac6f0e69a3f3c21eb2b812cefe302d0721415514 Mon Sep 17 00:00:00 2001 From: davwas Date: Thu, 14 Sep 2023 13:08:40 +0200 Subject: [PATCH] fix redirect --- controllers/homework.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/controllers/homework.js b/controllers/homework.js index 1a87b5ca0d..f908914e21 100644 --- a/controllers/homework.js +++ b/controllers/homework.js @@ -370,8 +370,7 @@ const getDeleteHandler = (service, redirectToReferer) => (req, res, next) => { if (redirectToReferer) { redirectHelper.safeBackRedirect(req, res); } else { - res.sendStatus(200); - res.redirect(`/${service}`); + res.redirect(200, `/${service}`); } }).catch((err) => { next(err);