Map an internal error to a user-safe HTTP response.
Routes by error class:
Always logs the raw error to console.warn/console.error so the original detail remains accessible via wrangler tail.
console.warn
console.error
wrangler tail
The thrown value (unknown shape).
A Response with the right status and a one-sentence error body.
Response
Map an internal error to a user-safe HTTP response.
Routes by error class:
Always logs the raw error to
console.warn/console.errorso the original detail remains accessible viawrangler tail.