Skip to content

Commit f6323f6

Browse files
authored
[types] update ProxyAgent Options (timeout) (nodejs#1801)
1 parent 9f6c592 commit f6323f6

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

test/types/proxy-agent.test-d.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,15 @@ expectAssignable<ProxyAgent>(
1616
ca: [''],
1717
key: '',
1818
cert: '',
19-
servername: ''
19+
servername: '',
20+
timeout: 1
2021
},
2122
proxyTls: {
2223
ca: [''],
2324
key: '',
2425
cert: '',
25-
servername: ''
26+
servername: '',
27+
timeout: 1
2628
}
2729
})
2830
)

types/proxy-agent.d.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { TlsOptions } from 'tls'
21
import Agent from './agent'
2+
import buildConnector from './connector';
33
import Dispatcher from './dispatcher'
44

55
export default ProxyAgent
@@ -19,7 +19,7 @@ declare namespace ProxyAgent {
1919
*/
2020
auth?: string;
2121
token?: string;
22-
requestTls?: TlsOptions & { servername?: string };
23-
proxyTls?: TlsOptions & { servername?: string };
22+
requestTls?: buildConnector.BuildOptions;
23+
proxyTls?: buildConnector.BuildOptions;
2424
}
2525
}

0 commit comments

Comments
 (0)