Skip to content

Commit 45e49fa

Browse files
committed
fix(dashboard): drain oversized request bodies
1 parent 44d0bc1 commit 45e49fa

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

packages/apm-contributor-dashboard/.apm/extensions/issue-monitor/server-handler.mjs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,8 @@ function readBody(req) {
9292
bytes += chunk.length;
9393
if (bytes > limit) {
9494
cleanup();
95-
req.destroy();
95+
req.once("error", () => {});
96+
req.resume();
9697
reject(createPayloadTooLargeError());
9798
return;
9899
}

0 commit comments

Comments
 (0)