diff --git a/src/Fasim/Core/Controller.php b/src/Fasim/Core/Controller.php index b050eac..7874736 100644 --- a/src/Fasim/Core/Controller.php +++ b/src/Fasim/Core/Controller.php @@ -197,7 +197,7 @@ public function display($html) { */ public function redirect($nextUrl, $location = true, $data = null) { if ($nextUrl{0} == '/') $nextUrl = substr($nextUrl, 1); - if (strlen($nextUrl) < 8 || substr($nextUrl, 0, 7) != 'http://' || substr($nextUrl, 0, 8) != 'https://') { + if (strlen($nextUrl) < 8 || (substr($nextUrl, 0, 7) != 'http://' && substr($nextUrl, 0, 8) != 'https://')) { $nextUrl = $this->config->baseUrl().$nextUrl; } if ($location) {