dub icon indicating copy to clipboard operation
dub copied to clipboard

This implementation handles errors in the API functions.

Open anirbanpaulcom opened this issue 10 months ago • 1 comments

Description :

This PR implements enhance Error handling in API functions.

anirbanpaulcom avatar Apr 12 '24 18:04 anirbanpaulcom

@anirbanpaulcom is attempting to deploy a commit to the Dub Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] avatar Apr 12 '24 18:04 vercel[bot]

@anirbanpaulcom Have you considered moving the handleAndReturnErrorResponse to the withAdmin method so that you don't have to add a try catch block in each API handler? What do you think?

devkiran avatar Apr 13 '24 06:04 devkiran

@anirbanpaulcom Have you considered moving the handleAndReturnErrorResponse to the withAdmin method so that you don't have to add a try catch block in each API handler? What do you think?

Yes @devkiran, is there any problem? Do i need to change anything?

anirbanpaulcom avatar Apr 13 '24 07:04 anirbanpaulcom

@anirbanpaulcom Let's move the error handling logic to withAdmin, so we don't have to repeat that on route level.

devkiran avatar Apr 16 '24 04:04 devkiran

@anirbanpaulcom Let's move the error handling logic to withAdmin, so we don't have to repeat that on route level.

@devkiran , Done. Anything else?

anirbanpaulcom avatar Apr 16 '24 04:04 anirbanpaulcom

Thanks for your contribution! I think these changes not necessary right now. I'm closing this PR.

devkiran avatar Apr 23 '24 15:04 devkiran