Files
codeql-action/node_modules/@octokit/webhooks/dist-src/middleware/node/handle-response.js
2025-05-27 12:34:30 +00:00

12 lines
264 B
JavaScript

function handleResponse(body, status = 200, headers = {}, response) {
if (body === null) {
return false;
}
headers["content-length"] = body.length.toString();
response.writeHead(status, headers).end(body);
return true;
}
export {
handleResponse
};