Skip to content

Commit

Permalink
fix: add /.debug/error route (#732)
Browse files Browse the repository at this point in the history
Motivation:
* #623 - see if errors from this show up different than errors from
ucanto HandlerExceptionError
  • Loading branch information
gobengo authored Apr 8, 2023
1 parent d1a35b7 commit 2ca5de8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/access-api/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ r.add('post', '/validate-email', validateEmail)
r.add('get', '/validate-ws', validateWS)
r.add('post', '/', postRoot)
r.add('post', '/raw', postRoot)
r.add('get', '/.debug/error', () => {
throw new Error('this is the result of handling a request at /.debug/error')
})

/** @type {import('./bindings.js').ModuleWorker} */
const worker = {
Expand Down

0 comments on commit 2ca5de8

Please sign in to comment.