Skip to content

Commit 875f16e

Browse files
Add TypeScript definitions for endWithoutBody (uNetworking#864)
1 parent 4774d92 commit 875f16e

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

docs/index.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,8 @@ export interface HttpResponse {
140140
write(chunk: RecognizedString) : boolean;
141141
/** Ends this response by copying the contents of body. */
142142
end(body?: RecognizedString, closeConnection?: boolean) : HttpResponse;
143+
/** Ends this response without a body. */
144+
endWithoutBody(reportedContentLength?: number, closeConnection?: boolean) : HttpResponse;
143145
/** Ends this response, or tries to, by streaming appropriately sized chunks of body. Use in conjunction with onWritable. Returns tuple [ok, hasResponded].*/
144146
tryEnd(fullBodyOrChunk: RecognizedString, totalSize: number) : [boolean, boolean];
145147

0 commit comments

Comments
 (0)