public static function hasEnvironmentVariable($name, bool $ignoreCase = false): bool
    {
        if (empty($name) || !is_string($name)) {
            return false;
        }
        
        return (getenv($name) || ArrayUtils::doesArrayHaveValueForKey($_ENV, $name, $ignoreCase));
    }
public static function hasEnvironmentVariable($name, bool $ignoreCase = false): bool
    {
        if (empty($name) || !is_string($name)) {
            return false;
        }
        
        return (getenv($name) || ArrayUtils::doesArrayHaveValueForKey($_ENV, $name, $ignoreCase));
    }
public static function hasEnvironmentVariable ( $ name , bool $ ignoreCase = false ) : bool { if ( empty ( $ name ) || ! is_string ( $ name ) ) { return false ; } return ( getenv ( $ name ) || ArrayUtils :: doesArrayHaveValueForKey ( $ _ENV , $ name , $ ignoreCase ) ) ; }
Check if environment variable with specified name exists.

@param string $name
The name of the environment variable to check for.

@param bool $ignoreCase
[optional]
Whether to treat lowercase and uppercase letters as equivalent during the search.

@return bool Whether an environment variable with specified name exists.
Check if environment variable with specified name exists .