Skip to content

Commit

Permalink
feat: Config updates for api-platform 3.3
Browse files Browse the repository at this point in the history
  • Loading branch information
ambroisemaupate committed Jul 24, 2024
1 parent c383b6f commit 3baf2d0
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
10 changes: 10 additions & 0 deletions config/packages/api_platform.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,16 @@ parameters:
env(HTTP_CACHE_SHARED_MAX_AGE): 600

api_platform:
# required for WebResponse and CommonContent endpoints
use_symfony_listeners: true
formats:
jsonld: ['application/ld+json']
json: ['application/json']
x-www-form-urlencoded: ['application/x-www-form-urlencoded']
docs_formats:
jsonld: ['application/ld+json']
jsonopenapi: ['application/vnd.openapi+json']
html: ['text/html']
patch_formats:
json: ['application/merge-patch+json']
enable_swagger_ui: true
Expand Down
1 change: 1 addition & 0 deletions config/packages/framework.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ framework:
trusted_proxies: '%env(TRUSTED_PROXIES)%'
#csrf_protection: true
http_method_override: false
handle_all_throwables: true

# Enables session support. Note that the session will ONLY be started if you read or write from it.
# Remove or comment this section to explicitly disable session support.
Expand Down
1 change: 0 additions & 1 deletion src/TreeWalker/MenuNodeSourceWalker.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

namespace App\TreeWalker;

use Psr\Cache\InvalidArgumentException;
use RZ\Roadiz\Contracts\NodeType\NodeTypeInterface;
use RZ\Roadiz\CoreBundle\Api\TreeWalker\Definition\MultiTypeChildrenDefinition;
use RZ\Roadiz\CoreBundle\Api\TreeWalker\NodeSourceWalkerContext;
Expand Down

0 comments on commit 3baf2d0

Please sign in to comment.