diff --git a/packages/http-client/src/proxy.ts b/packages/http-client/src/proxy.ts index 8a11ce99..78b1dbfe 100644 --- a/packages/http-client/src/proxy.ts +++ b/packages/http-client/src/proxy.ts @@ -16,10 +16,9 @@ export function getProxyUrl(reqUrl: URL): URL | undefined { if (proxyVar) { try { return new URL(proxyVar) - } - catch { + } catch { if (!proxyVar.startsWith('http://') && !proxyVar.startsWith('https://')) - return new URL('http://' + proxyVar) + return new URL('http://' + proxyVar) } } else { return undefined