File tree Expand file tree Collapse file tree 4 files changed +11
-3
lines changed Expand file tree Collapse file tree 4 files changed +11
-3
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ " @smithy/fetch-http-handler " : patch
3
+ " @smithy/node-http-handler " : patch
4
+ ---
5
+
6
+ align ctor and static creation signatures for http handlers
Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ export class FetchHttpHandler implements HttpHandler<FetchHttpHandlerConfig> {
32
32
* @returns the input if it is an HttpHandler of any class,
33
33
* or instantiates a new instance of this handler.
34
34
*/
35
- public static create ( instanceOrOptions ?: HttpHandler < any > | FetchHttpHandlerConfig ) {
35
+ public static create ( instanceOrOptions ?: HttpHandler < any > | FetchHttpHandlerOptions | Provider < FetchHttpHandlerOptions | undefined > ) {
36
36
if ( typeof ( instanceOrOptions as any ) ?. handle === "function" ) {
37
37
// is already an instance of HttpHandler.
38
38
return instanceOrOptions as HttpHandler < any > ;
Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ export class NodeHttpHandler implements HttpHandler<NodeHttpHandlerOptions> {
34
34
* @returns the input if it is an HttpHandler of any class,
35
35
* or instantiates a new instance of this handler.
36
36
*/
37
- public static create ( instanceOrOptions ?: HttpHandler < any > | NodeHttpHandlerOptions ) {
37
+ public static create ( instanceOrOptions ?: HttpHandler < any > | NodeHttpHandlerOptions | Provider < NodeHttpHandlerOptions | void > ) {
38
38
if ( typeof ( instanceOrOptions as any ) ?. handle === "function" ) {
39
39
// is already an instance of HttpHandler.
40
40
return instanceOrOptions as HttpHandler < any > ;
Original file line number Diff line number Diff line change @@ -53,7 +53,9 @@ export class NodeHttp2Handler implements HttpHandler<NodeHttp2HandlerOptions> {
53
53
* @returns the input if it is an HttpHandler of any class,
54
54
* or instantiates a new instance of this handler.
55
55
*/
56
- public static create ( instanceOrOptions ?: HttpHandler < any > | NodeHttp2HandlerOptions ) {
56
+ public static create (
57
+ instanceOrOptions ?: HttpHandler < any > | NodeHttp2HandlerOptions | Provider < NodeHttp2HandlerOptions | void >
58
+ ) {
57
59
if ( typeof ( instanceOrOptions as any ) ?. handle === "function" ) {
58
60
// is already an instance of HttpHandler.
59
61
return instanceOrOptions as HttpHandler < any > ;
You can’t perform that action at this time.
0 commit comments