From 240e621a5776067fdd0c17f917ff77f6b4937882 Mon Sep 17 00:00:00 2001 From: binsee <5285894+binsee@users.noreply.github.com> Date: Tue, 10 Oct 2023 16:00:08 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20=F0=9F=8F=B7=EF=B8=8F=20add=20allowH?= =?UTF-8?q?2=20to=20BuildOptions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- types/connector.d.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/types/connector.d.ts b/types/connector.d.ts index 847284a1f2b..bd924339eb3 100644 --- a/types/connector.d.ts +++ b/types/connector.d.ts @@ -6,6 +6,7 @@ declare function buildConnector (options?: buildConnector.BuildOptions): buildCo declare namespace buildConnector { export type BuildOptions = (ConnectionOptions | TcpNetConnectOpts | IpcNetConnectOpts) & { + allowH2?: boolean; maxCachedSessions?: number | null; socketPath?: string | null; timeout?: number | null; From 797f13479add1dc89e6f5c17254155898b69171c Mon Sep 17 00:00:00 2001 From: binsee <5285894+binsee@users.noreply.github.com> Date: Wed, 11 Oct 2023 14:42:45 +0800 Subject: [PATCH 2/2] =?UTF-8?q?test:=20=E2=9C=85=20update=20test?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- test/types/connector.test-d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/types/connector.test-d.ts b/test/types/connector.test-d.ts index bbf07e1d396..923656974d1 100644 --- a/test/types/connector.test-d.ts +++ b/test/types/connector.test-d.ts @@ -4,7 +4,7 @@ import {ConnectionOptions, TLSSocket} from 'tls' import {Socket} from 'net' import {IpcNetConnectOpts, NetConnectOpts, TcpNetConnectOpts} from "net"; -const connector = buildConnector({ rejectUnauthorized: false }) +const connector = buildConnector({ rejectUnauthorized: false, allowH2: false }) expectAssignable(new Client('', { connect (opts: buildConnector.Options, cb: buildConnector.Callback) { connector(opts, (...args) => {