diff --git a/CHANGELOG.md b/CHANGELOG.md index 63c3a680f..f3ee77d9a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,7 @@ * Fixed `Flex Page` CRUD ACL when creating a new page (needs Flex Objects plugin update) [grav-plugin-flex-objects#115](https://github.com/trilbymedia/grav-plugin-flex-objects/issues/115) * Fixed the list of pages not showing up in admin [#3280](https://github.com/getgrav/grav/issues/3280) * Fixed text field min/max validation for UTF8 characters [#3281](https://github.com/getgrav/grav/issues/3281) + * Fixed redirects using wrong redirect code # v1.7.8 ## 03/17/2021 diff --git a/system/src/Grav/Common/Grav.php b/system/src/Grav/Common/Grav.php index d9ad28957..c9097eea8 100644 --- a/system/src/Grav/Common/Grav.php +++ b/system/src/Grav/Common/Grav.php @@ -426,7 +426,7 @@ class Grav extends Container // Clean route for redirect $route = preg_replace("#^\/[\\\/]+\/#", '/', $route); - if (null !== $code || $code < 300 || $code > 399) { + if ($code < 300 || $code > 399) { $code = null; }