Completed
Push — master ( 324ca9...bf4d68 )
by Sullivan
8s
created

NexySlackExtension::load()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 9
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 9
rs 9.6666
cc 1
eloc 6
nc 1
nop 2
1
<?php
2
3
namespace Nexy\SlackBundle\DependencyInjection;
4
5
use Symfony\Component\DependencyInjection\ContainerBuilder;
6
use Symfony\Component\HttpKernel\DependencyInjection\Extension;
7
8
class NexySlackExtension extends Extension
9
{
10
    /**
11
     * {@inheritdoc}
12
     */
13
    public function load(array $configs, ContainerBuilder $container)
14
    {
15
        $configuration = new Configuration();
16
        $config = $this->processConfiguration($configuration, $configs);
17
18
        $container->setParameter('nexy_slack.endpoint', $config['endpoint']);
19
        unset($config['endpoint']);
20
        $container->setParameter('nexy_slack.config', $config);
21
    }
22
}
23