1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-13 08:34:19 +02:00

refactor(core): code updates and improvements - doctrine

This commit is contained in:
Awilum
2022-07-07 15:55:21 +03:00
parent 5a344b6c52
commit eeb0875a1a
11 changed files with 42 additions and 32 deletions

View File

@@ -18,23 +18,12 @@ namespace Flextype;
use function getcwd;
use function is_file;
use function sprintf;
use function str_replace;
/**
* Define the Flextype start time in current unix timestamp (microseconds).
*/
define('FLEXTYPE_START_TIME', microtime(true));
/**
* Define the PATH to the root directory (without trailing slash).
*/
define('FLEXTYPE_ROOT_DIR', str_replace(DIRECTORY_SEPARATOR, '/', getcwd()));
/**
* Ensure vendor libraries exist
*/
! is_file($flextypeAutoload = __DIR__ . '/vendor/autoload.php') and exit('Please run: <i>composer install</i> for flextype');
! is_file($flextypeAutoload = str_replace(DIRECTORY_SEPARATOR, '/', getcwd()) . '/vendor/autoload.php') and exit('Please run: <i>composer install</i> for flextype');
/**
* Register The Auto Loader