private function resolveNamespace(RequestStack $requestStack = null)
    {
        if ($requestStack !== null && ($request = $requestStack->getMasterRequest())) {
            return $request->isSecure() ? 'https-' : '';
        }

        return !empty($_SERVER['HTTPS']) && 'off' !== strtolower($_SERVER['HTTPS']) ? 'https-' : '';
    }