Skip to content

Commit

Permalink
set exception_to_status
Browse files Browse the repository at this point in the history
  • Loading branch information
pmattmann authored and BacLuc committed Oct 29, 2024
1 parent b0d5ef0 commit 79571ca
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions api/config/packages/api_platform.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,14 @@ api_platform:
order:
createTime: DESC
keep_legacy_inflector: false

# On API-Platform Update - test, if this config is still needed.
# See PR 5948: https://github.com/ecamp/ecamp3/pull/5948
exception_to_status:
# Default
Symfony\Component\Serializer\Exception\ExceptionInterface: 400
ApiPlatform\Metadata\Exception\InvalidArgumentException: 400
ApiPlatform\ParameterValidator\Exception\ValidationExceptionInterface: 400
Doctrine\ORM\OptimisticLockException: 409
# Legacy
ApiPlatform\Exception\InvalidArgumentException: 400

0 comments on commit 79571ca

Please sign in to comment.