public static function getString(array $array, $key, string $default = '') : string
    {
        $key = (string) $key;

        if ($array[$key] ?? 0) {
            return (string) $array[$key];
        }

        return $default;
    }