Skip to content

Commit 5407eba

Browse files
committed
Use allowH2 for both connections (microsoft/vscode#235410)
1 parent 8e32b6f commit 5407eba

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -597,8 +597,8 @@ export function createFetchPatch(params: ProxyAgentParams, originalFetch: typeof
597597
uri: proxyURL,
598598
allowH2,
599599
headers: proxyAuthorization ? { 'Proxy-Authorization': proxyAuthorization } : undefined,
600-
...(requestCA ? { requestTls: { ca: requestCA } } : {}),
601-
...(proxyCA ? { proxyTls: { ca: proxyCA } } : {}),
600+
requestTls: requestCA ? { allowH2, ca: requestCA } : { allowH2 },
601+
proxyTls: proxyCA ? { allowH2, ca: proxyCA } : { allowH2 },
602602
clientFactory: (origin: URL, opts: object): undici.Dispatcher => (new undici.Pool(origin, opts) as any).compose((dispatch: undici.Dispatcher['dispatch']) => {
603603
class ProxyAuthHandler extends undici.DecoratorHandler {
604604
private abort: ((err?: Error) => void) | undefined;

0 commit comments

Comments
 (0)