Skip to content

Commit

Permalink
fix(router): req.params compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 committed Mar 29, 2022
1 parent f9e269b commit 1d9fca0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ export function createRouter (): Router {

// Add params
event.event.params = matched.params || {}
// @ts-ignore Compatibility
event.req.params = event.event.params

// Call handler
return handler(event)
Expand Down

0 comments on commit 1d9fca0

Please sign in to comment.