Fix CLI mode detection for some shared hosts.
This commit is contained in:
parent
38562d5007
commit
d051994e2c
|
@ -196,7 +196,7 @@ public static function time()
|
||||||
*/
|
*/
|
||||||
public static function cli()
|
public static function cli()
|
||||||
{
|
{
|
||||||
return defined('STDIN');
|
return defined('STDIN') || (substr(PHP_SAPI, 0, 3) == 'cgi' && getenv('TERM'));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue