Skip to content

Commit

Permalink
Merge pull request #67 from natewiebe13/symfony-5-compatibility
Browse files Browse the repository at this point in the history
Symfony 5 Compatibility
  • Loading branch information
l3pp4rd authored Dec 30, 2019
2 parents 2582d9f + 0d9a611 commit 860c2d4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

"require": {
"php": ">=5.4.0",
"symfony/framework-bundle": "^2.6|^3.0|^4.0",
"symfony/framework-bundle": "^2.6|^3.0|^4.0|^5.0",
"doctrine/orm": "^2.4"
},

Expand All @@ -28,7 +28,7 @@
"ext-pdo": "*",
"ext-pdo_sqlite": "*",

"symfony/symfony": "^3.0|^4.0",
"symfony/symfony": "^3.0|^4.0|^5.0",
"doctrine/orm": "^2.5",
"doctrine/doctrine-bundle": "^1.6",
"doctrine/doctrine-fixtures-bundle": "^2.2",
Expand Down
5 changes: 3 additions & 2 deletions src/DataDog/AuditBundle/DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,9 @@ class Configuration implements ConfigurationInterface
*/
public function getConfigTreeBuilder()
{
$treeBuilder = new TreeBuilder();
$rootNode = $treeBuilder->root('data_dog_audit');
$treeBuilder = new TreeBuilder('data_dog_audit');
// BC layer for symfony/config < 4.2
$rootNode = method_exists($treeBuilder, 'getRootNode') ? $treeBuilder->getRootNode() : $treeBuilder->root('data_dog_audit');

$rootNode
->children()
Expand Down

0 comments on commit 860c2d4

Please sign in to comment.