We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 453bb88 commit a4b25ccCopy full SHA for a4b25cc
src/httpClient/httpURLConnectionClient.ts
@@ -118,7 +118,15 @@ class HttpURLConnectionClient implements ClientInterface {
118
requestOptions.headers[ApiConstants.ADYEN_LIBRARY_NAME] = LibraryConstants.LIB_NAME;
119
requestOptions.headers[ApiConstants.ADYEN_LIBRARY_VERSION] = LibraryConstants.LIB_VERSION;
120
121
- return httpsRequest(requestOptions);
+ // create a new ClientRequest object
122
+ const req = httpsRequest(requestOptions);
123
+
124
+ // set the timeout on the ClientRequest instance
125
+ if (requestOptions.timeout) {
126
+ req.setTimeout(requestOptions.timeout);
127
+ }
128
129
+ return req;
130
}
131
132
private getQuery(params: [string, string][]): string {
0 commit comments