diff --git a/index.php b/index.php index 51d9f55d8..d031fb0f7 100644 --- a/index.php +++ b/index.php @@ -1,7 +1,6 @@ PHP %s to run.', $ver, $req)); + die(sprintf('You are running PHP %s, but Grav needs at least PHP %s to run.', $ver, $req)); } // Set timezone to default, falls back to system if php.ini not set date_default_timezone_set(@date_default_timezone_get()); // Set internal encoding if mbstring loaded -if (!extension_loaded('mbstring')) { - throw new \RuntimeException("'mbstring' extension is not loaded. This is required for Grav to run correctly"); +if (extension_loaded('mbstring')) { + die("'mbstring' extension is not loaded. This is required for Grav to run correctly"); } mb_internal_encoding('UTF-8'); @@ -40,4 +39,3 @@ try { $grav->fireEvent('onFatalException'); throw $e; } -