Skip to content
This repository was archived by the owner on May 18, 2020. It is now read-only.

Commit 396f98c

Browse files
authored
Merge pull request #7 from MatTheCat/master
cleanup
2 parents e1db4b6 + c8ff14a commit 396f98c

File tree

3 files changed

+143
-143
lines changed

3 files changed

+143
-143
lines changed

DependencyInjection/Configuration.php

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,27 +5,19 @@
55
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
66
use Symfony\Component\Config\Definition\ConfigurationInterface;
77

8-
/**
9-
* This is the class that validates and merges configuration from your app/config files
10-
*
11-
* To learn more see {@link http://symfony.com/doc/current/cookbook/bundles/extension.html#cookbook-bundles-extension-config-class}
12-
*/
138
class Configuration implements ConfigurationInterface
149
{
1510
/**
16-
* {@inheritDoc}
11+
* {@inheritdoc}
1712
*/
1813
public function getConfigTreeBuilder()
1914
{
2015
$treeBuilder = new TreeBuilder();
2116
$rootNode = $treeBuilder->root('sendinblue_api');
2217

23-
// Here you should define the parameters that are allowed to
24-
// configure your bundle. See the documentation linked above for
25-
// more information on that topic.
2618
$rootNode->children()
2719
->scalarNode('api_key')->isRequired()->cannotBeEmpty()->end()
28-
->scalarNode('timeout')->defaultValue(30000)->end() //default timeout: 30 secs
20+
->integerNode('timeout')->min(0)->max(60000)->defaultValue(30000)->end() //default timeout: 30 secs
2921
->end();
3022

3123
return $treeBuilder;

DependencyInjection/SendinBlueApiExtension.php

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,10 @@
77
use Symfony\Component\HttpKernel\DependencyInjection\Extension;
88
use Symfony\Component\DependencyInjection\Loader;
99

10-
/**
11-
* This is the class that loads and manages your bundle configuration
12-
*
13-
* To learn more see {@link http://symfony.com/doc/current/cookbook/bundles/extension.html}
14-
*/
1510
class SendinBlueApiExtension extends Extension
1611
{
1712
/**
18-
* {@inheritDoc}
13+
* {@inheritdoc}
1914
*/
2015
public function load(array $configs, ContainerBuilder $container)
2116
{
@@ -24,6 +19,6 @@ public function load(array $configs, ContainerBuilder $container)
2419

2520
$loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
2621
$loader->load('services.yml');
27-
$container->setParameter('sendin_blue_api.config',$config);
22+
$container->setParameter('sendin_blue_api.config', $config);
2823
}
2924
}

0 commit comments

Comments
 (0)