1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-11 15:44:49 +02:00

refactor(flextype): move some core stuff from index file to flextype core

This commit is contained in:
Awilum
2022-04-05 18:47:24 +03:00
parent dc8fc49160
commit 41848400a5
2 changed files with 11 additions and 15 deletions

View File

@@ -16,19 +16,10 @@ declare(strict_types=1);
namespace Flextype;
use function define;
use function getcwd;
use function is_file;
use function sprintf;
use function str_replace;
use function version_compare;
use const DIRECTORY_SEPARATOR;
use const PHP_VERSION;
/**
* Define the application minimum supported PHP version.
*/
define('FLEXTYPE_MINIMUM_PHP', '7.4.0');
/**
* Define the PATH to the root directory (without trailing slash).
@@ -43,11 +34,6 @@ define('PATH', [
'tmp' => ROOT_DIR . '/var/tmp',
]);
/**
* Check PHP Version
*/
version_compare($ver = PHP_VERSION, $req = FLEXTYPE_MINIMUM_PHP, '<') and exit(sprintf('You are running PHP %s, but Flextype needs at least <strong>PHP %s</strong> to run.', $ver, $req));
/**
* Ensure vendor libraries exist
*/