Moved backend DI definitions
This commit is contained in:
parent
e13db65f68
commit
5573c49985
3 changed files with 4 additions and 4 deletions
|
@ -1,6 +1,6 @@
|
|||
[database]
|
||||
host = localhost
|
||||
port = 27017;
|
||||
port = 27017
|
||||
name = booru-dev
|
||||
|
||||
[security]
|
||||
|
|
|
@ -7,7 +7,7 @@ require_once(__DIR__ . DS . '..' . DS . 'src' . DS . 'AutoLoader.php');
|
|||
|
||||
$builder = new \DI\ContainerBuilder();
|
||||
$builder->setDefinitionCache(new Doctrine\Common\Cache\ArrayCache());
|
||||
$builder->addDefinitions(__DIR__ . DS . '..' . DS . 'di.php');
|
||||
$builder->addDefinitions(__DIR__ . DS . '..' . DS . 'src' . DS . 'di.php');
|
||||
$container = $builder->build();
|
||||
$dispatcher = $container->get('Szurubooru\Dispatcher');
|
||||
$dispatcher->run();
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
<?php
|
||||
return [
|
||||
\Szurubooru\Config::class => DI\object()->constructor([
|
||||
__DIR__ . DS . 'config.ini',
|
||||
__DIR__ . DS . 'local.ini']),
|
||||
__DIR__ . DS . '..' . DS . 'config.ini',
|
||||
__DIR__ . DS . '..' . DS . 'local.ini']),
|
||||
|
||||
\Szurubooru\ControllerRepository::class => DI\object()->constructor(DI\link('controllers')),
|
||||
|
Loading…
Reference in a new issue