]> git.immae.eu Git - github/wallabag/wallabag.git/blame_incremental - src/Wallabag/CoreBundle/DependencyInjection/WallabagCoreExtension.php
Merge pull request #1524 from wallabag/sf2.8
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / DependencyInjection / WallabagCoreExtension.php
... / ...
CommitLineData
1<?php
2
3namespace Wallabag\CoreBundle\DependencyInjection;
4
5use Symfony\Component\Config\FileLocator;
6use Symfony\Component\DependencyInjection\ContainerBuilder;
7use Symfony\Component\DependencyInjection\Loader;
8use Symfony\Component\HttpKernel\DependencyInjection\Extension;
9
10class WallabagCoreExtension extends Extension
11{
12 public function load(array $configs, ContainerBuilder $container)
13 {
14 $configuration = new Configuration();
15 $config = $this->processConfiguration($configuration, $configs);
16 $container->setParameter('wallabag_core.languages', $config['languages']);
17
18 $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
19 $loader->load('services.yml');
20 }
21
22 public function getAlias()
23 {
24 return 'wallabag_core';
25 }
26}