Skip to content

Commit

Permalink
Merge pull request #12 from bookboon/hotfix/root-node
Browse files Browse the repository at this point in the history
Use TreeBuilder constructor, deprecated using RootNode
  • Loading branch information
lkm authored Nov 25, 2019
2 parents 6073b93 + 58e7c00 commit ed460d5
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@ class Configuration implements ConfigurationInterface
*/
public function getConfigTreeBuilder()
{
$treeBuilder = new TreeBuilder();
$rootNode = $treeBuilder->root('bookboonapi');
$treeBuilder = new TreeBuilder('bookboonapi');

$rootNode->children()
$treeBuilder
->getRootNode()
->children()
->scalarNode('id')->isRequired()->end()
->scalarNode('secret')->isRequired()->end()
->scalarNode('branding')->end()
Expand All @@ -36,4 +37,4 @@ public function getConfigTreeBuilder()

return $treeBuilder;
}
}
}

0 comments on commit ed460d5

Please sign in to comment.