blob: dff4b23a2b413fdc7ecd5960c335bfa8c77b5304 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
<?php
namespace Kanboard\ServiceProvider;
use Pimple\Container;
use Pimple\ServiceProviderInterface;
use Kanboard\Core\Group\GroupManager;
use Kanboard\Group\DatabaseBackendGroupProvider;
use Kanboard\Group\LdapBackendGroupProvider;
/**
* Group Provider
*
* @package serviceProvider
* @author Frederic Guillot
*/
class GroupProvider implements ServiceProviderInterface
{
/**
* Register providers
*
* @access public
* @param \Pimple\Container $container
* @return \Pimple\Container
*/
public function register(Container $container)
{
$container['groupManager'] = new GroupManager;
$container['groupManager']->register(new DatabaseBackendGroupProvider($container));
if (LDAP_AUTH && LDAP_GROUP_PROVIDER) {
$container['groupManager']->register(new LdapBackendGroupProvider($container));
}
return $container;
}
}
|