public static function hasCookieToken(): bool
    {
        $cookieName = static::getCookieName();

        if ($cookieName === null || strlen($cookieName) == 0) {
            throw new Exception('Can not check if CSRF token is in cookie when cookie name is not set in CSRF configuration');
        }

        return Cookie::has($cookieName);
    }