sef-global / scholarx-backend

This is the backend of the ScholarX
MIT License
11 stars 41 forks source link

Request validation using zod #138

Closed dsmabulage closed 3 months ago

dsmabulage commented 4 months ago

Description:

Implement request validation for all request inputs using a validation library (Zod) . This ensures that all incoming data is properly validated before processing.

Tasks:

Acceptance Criteria:

dsmabulage commented 4 months ago

@anjula-sack can you assign this to me

anjula-sack commented 4 months ago

@dsmabulage Please use Zod

dsmabulage commented 4 months ago

@dsmabulage Please use Zod

issue updated

anjula-sack commented 4 months ago

Any updates on this? @dsmabulage

dsmabulage commented 4 months ago

Any updates on this? @dsmabulage

working on it

dsmabulage commented 4 months ago

Any updates on this? @dsmabulage

I have some suggestions for you about this.

  1. Error handling at the router level using middleware.
  2. Error handling at the controller level ( catch block can be complex in this approach)

Any suggestion of yours?

anjula-sack commented 4 months ago

Let's handle it at the router level @dsmabulage