summaryrefslogtreecommitdiffstats
path: root/apps/files
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2019-08-05 12:55:52 +0200
committerGitHub <noreply@github.com>2019-08-05 12:55:52 +0200
commit2ca8ff83f2537091f84b6fb4912524d124a67d40 (patch)
tree5e7ffdcd58b4c2bcc5ad893fb10ae6368ec3865d /apps/files
parenta6b1592bf0ee4993ce77d090cea8af237a1fb2df (diff)
parent2d9feca0a309d6d548bfa81fe2081c2441aa1a09 (diff)
downloadnextcloud-server-2ca8ff83f2537091f84b6fb4912524d124a67d40.tar.gz
nextcloud-server-2ca8ff83f2537091f84b6fb4912524d124a67d40.zip
Merge pull request #16643 from nextcloud/enh/moreDIUsage
Lets use DI where we can
Diffstat (limited to 'apps/files')
-rw-r--r--apps/files/lib/AppInfo/Application.php27
1 files changed, 1 insertions, 26 deletions
diff --git a/apps/files/lib/AppInfo/Application.php b/apps/files/lib/AppInfo/Application.php
index dc2ed59618e..cef4b31f85f 100644
--- a/apps/files/lib/AppInfo/Application.php
+++ b/apps/files/lib/AppInfo/Application.php
@@ -59,40 +59,15 @@ class Application extends App {
);
});
- $container->registerService('ViewController', function (IContainer $c) use ($server) {
- return new ViewController(
- $c->query('AppName'),
- $c->query('Request'),
- $server->getURLGenerator(),
- $c->query('L10N'),
- $server->getConfig(),
- $server->getEventDispatcher(),
- $server->getUserSession(),
- $server->getAppManager(),
- $server->getRootFolder(),
- $c->query(Helper::class)
- );
- });
-
- /**
- * Core
- */
- $container->registerService('L10N', function(IContainer $c) {
- return $c->query('ServerContainer')->getL10N($c->query('AppName'));
- });
-
/**
* Services
*/
- $container->registerService('Tagger', function(IContainer $c) {
- return $c->query('ServerContainer')->getTagManager()->load('files');
- });
$container->registerService('TagService', function(IContainer $c) use ($server) {
$homeFolder = $c->query('ServerContainer')->getUserFolder();
return new TagService(
$c->query('ServerContainer')->getUserSession(),
$c->query('ServerContainer')->getActivityManager(),
- $c->query('Tagger'),
+ $c->query('ServerContainer')->getTagManager()->load('files'),
$homeFolder,
$server->getEventDispatcher()
);