79142262

Date: 2024-10-30 17:56:35
Score: 2
Natty:
Report link

there's a third option and it's better than these two

use the request form for validation why? here are a few reasons

  1. the data validated before reaching to the controller
  2. it's cleaner if the validation separated from the logic
  3. it's following the solid principles

and according to your question , the best way is to use validatedData

why?

Because you will be sure the data is already validated and it's not passed without any validation,

rather than that there's no difference

Reasons:
  • Blacklisted phrase (0.5): why?
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (0.5):
Posted by: amr degheidy