public static function Utilities::drupal_is_cli in Drupal OAuth & OpenID Connect Login - OAuth2 Client SSO Login 7
1 call to Utilities::drupal_is_cli()
- miniorange_oauth_client_disable in ./
miniorange_oauth_client.install - Implements hook_disable().
File
- includes/
Utilities.php, line 239
Class
Code
public static function drupal_is_cli() {
if (!isset($_SERVER['SERVER_SOFTWARE']) && (php_sapi_name() == 'cli' || is_numeric($_SERVER['argc']) && $_SERVER['argc'] > 0)) {
return TRUE;
}
else {
return FALSE;
}
}