capnweb 0.9.0 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index-bun.cjs +5 -1
- package/dist/index-bun.cjs.map +1 -1
- package/dist/index-bun.js +5 -1
- package/dist/index-bun.js.map +1 -1
- package/dist/index-workers.cjs +5 -1
- package/dist/index-workers.cjs.map +1 -1
- package/dist/index-workers.js +5 -1
- package/dist/index-workers.js.map +1 -1
- package/dist/index.cjs +5 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index-bun.js
CHANGED
|
@@ -2305,7 +2305,11 @@ async function newHttpBatchRpcResponse(request, localMain, options) {
|
|
|
2305
2305
|
* @param options Optional RPC session options. You can also pass headers to set on the response.
|
|
2306
2306
|
*/
|
|
2307
2307
|
async function nodeHttpBatchRpcResponse(request, response, localMain, options) {
|
|
2308
|
-
if (request.method !== "POST")
|
|
2308
|
+
if (request.method !== "POST") {
|
|
2309
|
+
response.writeHead(405, "This endpoint only accepts POST requests.", options?.headers);
|
|
2310
|
+
response.end();
|
|
2311
|
+
return;
|
|
2312
|
+
}
|
|
2309
2313
|
let body = await new Promise((resolve, reject) => {
|
|
2310
2314
|
let chunks = [];
|
|
2311
2315
|
request.on("data", (chunk) => {
|