Skip to content

Commit

Permalink
fix(ApiResourceGenerator): Do not wrap *boolean* value in quotes
Browse files Browse the repository at this point in the history
  • Loading branch information
ambroisemaupate committed Jul 25, 2023
1 parent e4587a8 commit 90630c1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
5 changes: 2 additions & 3 deletions config/api_resources/nsoffer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ App\GeneratedEntity\NSOffer:
- document_thumbnails
- document_display_sources
getByPath:
method: 'GET'
path: '/web_response_by_path'
method: GET
path: /web_response_by_path
read: false
controller: RZ\Roadiz\CoreBundle\Api\Controller\GetWebResponseByPathController
pagination_enabled: false
Expand All @@ -49,4 +49,3 @@ App\GeneratedEntity\NSOffer:
- walker_metadata
- meta
- children
- children_count
5 changes: 2 additions & 3 deletions config/api_resources/nspage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ App\GeneratedEntity\NSPage:
- nodes_sources_images
- nodes_sources_boolean
getByPath:
method: 'GET'
path: '/web_response_by_path'
method: GET
path: /web_response_by_path
read: false
controller: RZ\Roadiz\CoreBundle\Api\Controller\GetWebResponseByPathController
pagination_enabled: false
Expand All @@ -55,4 +55,3 @@ App\GeneratedEntity\NSPage:
- walker_metadata
- meta
- children
- children_count
4 changes: 2 additions & 2 deletions lib/RoadizCoreBundle/src/NodeType/ApiResourceGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,9 @@ protected function getItemOperations(NodeTypeInterface $nodeType): array
$operations['getByPath'] = [
'method' => 'GET',
'path' => '/web_response_by_path',
'read' => 'false',
'read' => false,
'controller' => 'RZ\Roadiz\CoreBundle\Api\Controller\GetWebResponseByPathController',
'pagination_enabled' => 'false',
'pagination_enabled' => false,
'normalization_context' => [
'enable_max_depth' => true,
'groups' => array_merge(array_values(array_filter(array_unique($groups))), [
Expand Down

0 comments on commit 90630c1

Please sign in to comment.