Skip to content

Commit 56d4a9b

Browse files
AndrewLeedhamfengmk2
authored andcommitted
fix: HttpAgent export = internal (#74)
closes #73
1 parent f3d9c87 commit 56d4a9b

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

index.d.ts

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -30,21 +30,17 @@ declare module "agentkeepalive" {
3030
socketActiveTTL?: number;
3131
}
3232

33-
class internal extends http.Agent {
33+
export default class HttpAgent extends http.Agent {
3434
constructor(opts?: HttpOptions);
3535
readonly statusChanged: boolean;
3636
createSocket(req: http.IncomingMessage, options: http.RequestOptions, cb: Function): void;
3737
getCurrentStatus(): AgentStatus;
3838
}
3939

40-
namespace internal {
41-
export class HttpsAgent extends https.Agent {
42-
constructor(opts?: HttpsOptions);
43-
readonly statusChanged: boolean;
44-
createSocket(req: http.IncomingMessage, options: https.RequestOptions, cb: Function): void;
45-
getCurrentStatus(): AgentStatus;
46-
}
40+
export class HttpsAgent extends https.Agent {
41+
constructor(opts?: HttpsOptions);
42+
readonly statusChanged: boolean;
43+
createSocket(req: http.IncomingMessage, options: https.RequestOptions, cb: Function): void;
44+
getCurrentStatus(): AgentStatus;
4745
}
48-
49-
export = internal;
5046
}

0 commit comments

Comments
 (0)