what would be a better way of writing the following inside of middleware?
event.nativeEvent.res.writeHead(403).end();
return;
event.nativeEvent.res.writeHead(403).end();
return;
Returning a new Response() gives a type error (but works as expected) and just setting the event.response.status and returning doesn't end the response