You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: types/dispatcher.d.ts
+8-8Lines changed: 8 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -19,30 +19,30 @@ declare class Dispatcher extends EventEmitter {
19
19
/** Dispatches a request. This API is expected to evolve through semver-major versions and is less stable than the preceding higher level APIs. It is primarily intended for library developers who implement higher level APIs on top of this. */
/** Closes the client and gracefully waits for enqueued requests to complete before invoking the callback (or returning a promise if no callback is provided). */
39
-
close(): Promise<void>
40
39
close(callback: ()=>void): void
40
+
close(): Promise<void>
41
41
/** Destroy the client abruptly with the given err. All the pending and running requests will be asynchronously aborted and error. Waits until socket is closed before invoking the callback (or returning a promise if no callback is provided). Since this operation is asynchronously dispatched there might still be some progress on dispatched requests. */
42
-
destroy(): Promise<void>
43
-
destroy(err: Error|null): Promise<void>
44
-
destroy(callback: ()=>void): void
45
42
destroy(err: Error|null,callback: ()=>void): void
43
+
destroy(callback: ()=>void): void
44
+
destroy(err: Error|null): Promise<void>
45
+
destroy(): Promise<void>
46
46
47
47
on(eventName: 'connect',callback: (origin: URL,targets: readonlyDispatcher[])=>void): this
48
48
on(eventName: 'disconnect',callback: (origin: URL,targets: readonlyDispatcher[],error: Errors.UndiciError)=>void): this
0 commit comments