mirror of
https://github.com/owncloudarchive/contacts.git
synced 2025-01-18 07:52:21 +01:00
Fix php53 errors
This commit is contained in:
parent
adda72edab
commit
0e863592e6
@ -64,50 +64,51 @@ class Dispatcher extends MainApp {
|
||||
|
||||
public function registerServices() {
|
||||
$app = $this->app;
|
||||
$appName = $this->appName;
|
||||
|
||||
$this->container->registerService('HttpMiddleware', function($container) {
|
||||
return new HttpMiddleware();
|
||||
});
|
||||
|
||||
$this->container->registerService('PageController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('PageController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
return new PageController($this->appName, $request);
|
||||
return new PageController($appName, $request);
|
||||
});
|
||||
$this->container->registerService('AddressBookController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('AddressBookController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
$api = $container->query('API');
|
||||
return new AddressBookController($this->appName, $request, $app, $api);
|
||||
return new AddressBookController($appName, $request, $app, $api);
|
||||
});
|
||||
$this->container->registerService('BackendController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('BackendController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
return new BackendController($container, $request, $app);
|
||||
});
|
||||
$this->container->registerService('GroupController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('GroupController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
$tags = $this->server->getTagManager()->load('contact');
|
||||
return new GroupController($this->appName, $request, $app, $tags);
|
||||
$tags = $container->getServer()->getTagManager()->load('contact');
|
||||
return new GroupController($appName, $request, $app, $tags);
|
||||
});
|
||||
$this->container->registerService('ContactController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('ContactController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
return new ContactController($this->appName, $request, $app);
|
||||
return new ContactController($appName, $request, $app);
|
||||
});
|
||||
$this->container->registerService('ContactPhotoController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('ContactPhotoController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
$cache = $this->server->getCache();
|
||||
return new ContactPhotoController($this->appName, $request, $app, $cache);
|
||||
$cache = $container->getServer()->getCache();
|
||||
return new ContactPhotoController($appName, $request, $app, $cache);
|
||||
});
|
||||
$this->container->registerService('SettingsController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('SettingsController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
return new SettingsController($this->appName, $request, $app);
|
||||
return new SettingsController($appName, $request, $app);
|
||||
});
|
||||
$this->container->registerService('ImportController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('ImportController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
$cache = $this->server->getCache();
|
||||
return new ImportController($this->appName, $request, $app, $cache);
|
||||
$cache = $container->getServer()->getCache();
|
||||
return new ImportController($appName, $request, $app, $cache);
|
||||
});
|
||||
$this->container->registerService('ExportController', function(IAppContainer $container) use($app) {
|
||||
$this->container->registerService('ExportController', function(IAppContainer $container) use($app, $appName) {
|
||||
$request = $container->query('Request');
|
||||
return new ExportController($this->appName, $request, $app);
|
||||
return new ExportController($appName, $request, $app);
|
||||
});
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user