Skip to content
This repository has been archived by the owner on Dec 1, 2023. It is now read-only.

Commit

Permalink
Only enable json converter by default if "json_post" extension is not…
Browse files Browse the repository at this point in the history
… installed
  • Loading branch information
danielburger1337 committed Jul 28, 2023
1 parent afbc288 commit 0b8b233
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion config/definitions/json_converter.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
->treatFalseLike(['enabled' => false])
->addDefaultsIfNotSet()
->children()
->booleanNode('enabled')->defaultTrue()->end()
->booleanNode('enabled')
->defaultValue(!\extension_loaded('json_post'))
->end()
->arrayNode('content_types')
->info('The Content-Type headers on which this converter should act upon.')
->prototype('scalar')->end()
Expand Down

0 comments on commit 0b8b233

Please sign in to comment.