This bug is about replacing our calls to php_sapi_name() by the PHP building constant PHP_SAPI.
PHP_SAPI has been available since PHP 4.2 and provide the same string that php_sapi_name() provides. I find it shorter and cleaner to read. Consider:
if( php_sapi_name() !== 'cli ) { }
if( PHP_SAPI !== 'cli ) { }
Version: 1.20.x
Severity: enhancement