Explorar el Código

Use global Constant

Joanhey hace 6 años
padre
commit
ef96e6da38
Se han modificado 2 ficheros con 2 adiciones y 2 borrados
  1. 1 1
      Protocols/Http.php
  2. 1 1
      Worker.php

+ 1 - 1
Protocols/Http.php

@@ -723,4 +723,4 @@ class HttpCache
 
 HttpCache::init();
 
-define('NO_CLI', PHP_SAPI !== 'cli');
+define('NO_CLI', \PHP_SAPI !== 'cli');

+ 1 - 1
Worker.php

@@ -542,7 +542,7 @@ class Worker
     protected static function checkSapiEnv()
     {
         // Only for cli.
-        if (PHP_SAPI !== 'cli') {
+        if (\PHP_SAPI !== 'cli') {
             exit("Only run in command line mode \n");
         }
         if (DIRECTORY_SEPARATOR === '\\') {