From 5573c499851cc8d8c18d1decc4d98354ce34be65 Mon Sep 17 00:00:00 2001 From: Marcin Kurczewski Date: Tue, 2 Sep 2014 09:38:12 +0200 Subject: [PATCH] Moved backend DI definitions --- config.ini | 2 +- public_html/api-dispatch.php | 2 +- di.php => src/di.php | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) rename di.php => src/di.php (80%) diff --git a/config.ini b/config.ini index f44a8ef2..3359b8db 100644 --- a/config.ini +++ b/config.ini @@ -1,6 +1,6 @@ [database] host = localhost -port = 27017; +port = 27017 name = booru-dev [security] diff --git a/public_html/api-dispatch.php b/public_html/api-dispatch.php index c2b779d8..41da5375 100644 --- a/public_html/api-dispatch.php +++ b/public_html/api-dispatch.php @@ -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(); diff --git a/di.php b/src/di.php similarity index 80% rename from di.php rename to src/di.php index 90325b9b..b3d141ef 100644 --- a/di.php +++ b/src/di.php @@ -1,8 +1,8 @@ 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')),