diff --git a/Core/Frameworks/Baikal/Core/Tools.php b/Core/Frameworks/Baikal/Core/Tools.php index 6879258..25f7808 100644 --- a/Core/Frameworks/Baikal/Core/Tools.php +++ b/Core/Frameworks/Baikal/Core/Tools.php @@ -35,23 +35,23 @@ class Tools { static function assertEnvironmentIsOk() { # Asserting Baikal Context if (!defined("BAIKAL_CONTEXT") || BAIKAL_CONTEXT !== true) { - die("Bootstrap.php may not be included outside the Baikal context"); + exit("Bootstrap.php may not be included outside the Baikal context"); } # Asserting PDO if (!defined('PDO::ATTR_DRIVER_NAME')) { - die('Baikal Fatal Error: PDO is unavailable. It\'s required by Baikal.'); + exit('Baikal Fatal Error: PDO is unavailable. It\'s required by Baikal.'); } # Asserting PDO::SQLite or PDO::MySQL $aPDODrivers = \PDO::getAvailableDrivers(); if (!in_array('sqlite', $aPDODrivers, true) && !in_array('mysql', $aPDODrivers, true)) { - die('Baikal Fatal Error: Both PDO::sqlite and PDO::mysql are unavailable. One of them at least is required by Baikal.'); + exit('Baikal Fatal Error: Both PDO::sqlite and PDO::mysql are unavailable. One of them at least is required by Baikal.'); } # Assert that the temp folder is writable if (!\is_writable(\sys_get_temp_dir())) { - die('Baikal Fatal Error: The system temp directory is not writable.'); + exit('Baikal Fatal Error: The system temp directory is not writable.'); } } diff --git a/Core/Frameworks/Baikal/WWWRoot/index.php b/Core/Frameworks/Baikal/WWWRoot/index.php index d70abc6..1aa057c 100644 --- a/Core/Frameworks/Baikal/WWWRoot/index.php +++ b/Core/Frameworks/Baikal/WWWRoot/index.php @@ -40,7 +40,7 @@ if (file_exists(getcwd() . "/Core")) { } if (!file_exists(PROJECT_PATH_ROOT . 'vendor/')) { - die('
Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); + exit('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); } require PROJECT_PATH_ROOT . 'vendor/autoload.php'; diff --git a/Core/Frameworks/BaikalAdmin/Controller/Install/Initialize.php b/Core/Frameworks/BaikalAdmin/Controller/Install/Initialize.php index 25b4953..6d7f882 100644 --- a/Core/Frameworks/BaikalAdmin/Controller/Install/Initialize.php +++ b/Core/Frameworks/BaikalAdmin/Controller/Install/Initialize.php @@ -39,7 +39,7 @@ class Initialize extends \Flake\Core\Controller { $message = ""; $message .= "
In order to work properly, Baïkal needs to have write permissions in the Specific/ and config/ folder.
"; - die($message); + exit($message); } $this->createHtaccessFilesIfNeeded(); diff --git a/Core/Frameworks/BaikalAdmin/WWWRoot/index.php b/Core/Frameworks/BaikalAdmin/WWWRoot/index.php index 0f9d83e..31afd48 100644 --- a/Core/Frameworks/BaikalAdmin/WWWRoot/index.php +++ b/Core/Frameworks/BaikalAdmin/WWWRoot/index.php @@ -41,7 +41,7 @@ if (file_exists(dirname(getcwd()) . "/Core")) { } if (!file_exists(PROJECT_PATH_ROOT . 'vendor/')) { - die('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); + exit('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); } require PROJECT_PATH_ROOT . 'vendor/autoload.php'; diff --git a/Core/Frameworks/BaikalAdmin/WWWRoot/install/index.php b/Core/Frameworks/BaikalAdmin/WWWRoot/install/index.php index 93038d3..ba3414b 100644 --- a/Core/Frameworks/BaikalAdmin/WWWRoot/install/index.php +++ b/Core/Frameworks/BaikalAdmin/WWWRoot/install/index.php @@ -48,7 +48,7 @@ if (file_exists(dirname(dirname(getcwd())) . "/Core")) { } if (!file_exists(PROJECT_PATH_ROOT . 'vendor/')) { - die('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); + exit('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); } require PROJECT_PATH_ROOT . "vendor/autoload.php"; @@ -92,7 +92,7 @@ if (!$config || !isset($config['system']["configured_version"])) { $oPage->zone("Payload")->addBlock(new \BaikalAdmin\Controller\Install\Database()); } else { echo "Installation was already completed. Please head to the admin interface to modify any settings.\n"; - die(); + exit(); } } diff --git a/Core/Frameworks/Flake/Controller/Cli.php b/Core/Frameworks/Flake/Controller/Cli.php index 9fd8032..4f41a27 100644 --- a/Core/Frameworks/Flake/Controller/Cli.php +++ b/Core/Frameworks/Flake/Controller/Cli.php @@ -81,7 +81,7 @@ class Cli extends \Flake\Core\Render\Container { function syntaxError() { $sStr = $this->rawLine("Syntax error.\nUsage: " . $this->getSyntax()); - die("\n\n" . $sStr . "\n\n"); + exit("\n\n" . $sStr . "\n\n"); } function log($sStr) { diff --git a/Core/Frameworks/Flake/Controller/Page.php b/Core/Frameworks/Flake/Controller/Page.php index 7d4e1de..5267409 100644 --- a/Core/Frameworks/Flake/Controller/Page.php +++ b/Core/Frameworks/Flake/Controller/Page.php @@ -115,7 +115,7 @@ class Page extends \Flake\Core\Render\Container { if (!file_exists($sCompiledPath)) { @mkdir($sCompiledPath); if (!file_exists($sCompiledPath)) { - die("Page: Cannot create " . $sCompiledPath); + exit("Page: Cannot create " . $sCompiledPath); } } diff --git a/Core/Frameworks/Flake/Core/Database.php b/Core/Frameworks/Flake/Core/Database.php index 8a17d47..4bc0b8a 100644 --- a/Core/Frameworks/Flake/Core/Database.php +++ b/Core/Frameworks/Flake/Core/Database.php @@ -37,7 +37,7 @@ abstract class Database extends \Flake\Core\FLObject { protected function messageAndDie($sMessage) { $sError = "Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); + exit('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); } require PROJECT_PATH_ROOT . 'vendor/autoload.php'; @@ -56,7 +56,7 @@ require PROJECT_PATH_ROOT . 'vendor/autoload.php'; try { $config = Yaml::parseFile(PROJECT_PATH_CONFIG . "baikal.yaml"); } catch (\Exception $e) { - die('Baïkal is missing its configuration file, or its configuration file is unreadable.'); + exit('
Baïkal is missing its configuration file, or its configuration file is unreadable.'); } if (!isset($config['system']["cal_enabled"]) || $config['system']["cal_enabled"] !== true) { diff --git a/html/card.php b/html/card.php index 91de6bd..6a41053 100644 --- a/html/card.php +++ b/html/card.php @@ -42,7 +42,7 @@ if (file_exists(getcwd() . "/Core")) { } if (!file_exists(PROJECT_PATH_ROOT . 'vendor/')) { - die('
Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); + exit('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); } require PROJECT_PATH_ROOT . 'vendor/autoload.php'; @@ -56,7 +56,7 @@ require PROJECT_PATH_ROOT . 'vendor/autoload.php'; try { $config = Yaml::parseFile(PROJECT_PATH_CONFIG . "baikal.yaml"); } catch (\Exception $e) { - die('Baïkal is missing its configuration file, or its configuration file is unreadable.'); + exit('
Baïkal is missing its configuration file, or its configuration file is unreadable.'); } if (!isset($config['system']["card_enabled"]) || $config['system']["card_enabled"] !== true) { diff --git a/html/dav.php b/html/dav.php index be51362..642f6ba 100644 --- a/html/dav.php +++ b/html/dav.php @@ -42,7 +42,7 @@ if (file_exists(getcwd() . "/Core")) { } if (!file_exists(PROJECT_PATH_ROOT . 'vendor/')) { - die('
Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); + exit('Baïkal dependencies have not been installed. If you are a regular user, this means that you probably downloaded the wrong zip file.
To install the dependencies manually, execute "composer install" in the Baïkal root folder.
'); } require PROJECT_PATH_ROOT . 'vendor/autoload.php'; @@ -55,7 +55,7 @@ require PROJECT_PATH_ROOT . 'vendor/autoload.php'; try { $config = Yaml::parseFile(PROJECT_PATH_CONFIG . "baikal.yaml"); } catch (\Exception $e) { - die('Baïkal is missing its configuration file, or its configuration file is unreadable.'); + exit('
Baïkal is missing its configuration file, or its configuration file is unreadable.'); } $server = new \Baikal\Core\Server(