Skip to content

Commit b683cd8

Browse files
author
v 1 r t l
authored
Merge pull request #17 from Sceat/patch-1
Parse body on `DELETE` requests
2 parents f6975e0 + 3be6d65 commit b683cd8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export type ReqWithBody<T = any> = IncomingMessage & {
88
body?: T
99
} & EventEmitter
1010

11-
export const hasBody = (method: string) => ['POST', 'PUT', 'PATCH'].includes(method)
11+
export const hasBody = (method: string) => ['POST', 'PUT', 'PATCH', 'DELETE'].includes(method)
1212

1313
// Main function
1414
export const p =

0 commit comments

Comments
 (0)