Replies: 1 comment 1 reply
-
|
Hey! It's been going well, busy holidays and all! As for that handler, I think that's because when I started out with the boilerplate template I had made it. I think considering all routes are wrapped in try catch it certainly would be quite a rewrite, however I would like to avoid using too many packages to accomplish things (it's been an absolute terror to upgrade these in the past few days haha). I can definitely take a look in the new year here once I'm a bit more settled with personal matters though :) thanks for pointing this out! |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey @PhlexPlexico hope you doing fine,
I notice you added this error handler middleware
G5API/app.js
Lines 188 to 196 in c8fa5fc
But it doesn't seem to be called since all routes are handled with try-catch blocks.
So, I would suggest using this package which allows removing try-catch block safely and make the code a little bit cleaner
https://www.npmjs.com/package/express-async-errors
Beta Was this translation helpful? Give feedback.
All reactions