From 7814697f825d4963886979c0e048dd874a3a8852 Mon Sep 17 00:00:00 2001 From: Hugo Sales Date: Fri, 4 Mar 2022 15:15:04 +0000 Subject: [PATCH] [UTIL][EXCEPTION] Forward given status code in RedirectException --- src/Util/Exception/RedirectException.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Util/Exception/RedirectException.php b/src/Util/Exception/RedirectException.php index b28e4cd827..dce2abba58 100644 --- a/src/Util/Exception/RedirectException.php +++ b/src/Util/Exception/RedirectException.php @@ -46,7 +46,7 @@ class RedirectException extends Exception throw new ServerException(_m('Can not redirect to outside the website from here'), 5400); // 500 Internal server error (likely a bug) } } - $this->redirect_response = new RedirectResponse($url); + $this->redirect_response = new RedirectResponse($url, $code); } parent::__construct($message, $code, $previous_exception); }