A free open source IT asset/license management system
Change validation failure to 422 to make it consistent with Laravel's default
snipe81b66d003973
diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.phpindex de890d3e4d..7fd552f57d 100644--- a/app/Exceptions/Handler.php+++ b/app/Exceptions/Handler.php@@ -121,6 +121,6 @@ class Handler extends ExceptionHandler*/protected function invalidJson($request, ValidationException $exception){- return response()->json(Helper::formatStandardApiResponse('error', null, $exception->errors(), 400));+ return response()->json(Helper::formatStandardApiResponse('error', null, $exception->errors(), 422));}}