diff options
author | Robin Appelman <icewind@owncloud.com> | 2015-10-05 16:39:11 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2015-10-05 16:39:11 +0200 |
commit | e1c562f66b8547e0418a14f9f4fe8616c622caa8 (patch) | |
tree | f64a3387fe269ecc2a4b36382d32b674346b0a6a /apps/files_sharing/appinfo | |
parent | a0c9dc298680eaa4f9f077978d8baefdec102d93 (diff) | |
download | nextcloud-server-e1c562f66b8547e0418a14f9f4fe8616c622caa8.tar.gz nextcloud-server-e1c562f66b8547e0418a14f9f4fe8616c622caa8.zip |
extract the mount provider from the manager
Diffstat (limited to 'apps/files_sharing/appinfo')
-rw-r--r-- | apps/files_sharing/appinfo/application.php | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/apps/files_sharing/appinfo/application.php b/apps/files_sharing/appinfo/application.php index c3e2a1d707d..872229fa743 100644 --- a/apps/files_sharing/appinfo/application.php +++ b/apps/files_sharing/appinfo/application.php @@ -118,6 +118,17 @@ class Application extends App { ); }); + $container->registerService('ExternalMountProvider', function (IContainer $c) { + /** @var \OCP\IServerContainer $server */ + $server = $c->query('ServerContainer'); + return new \OCA\Files_Sharing\External\MountProvider( + $server->getDatabaseConnection(), + function() use ($c) { + return $c->query('ExternalManager'); + } + ); + }); + $container->registerService('PropagationManager', function (IContainer $c) { /** @var \OCP\IServerContainer $server */ $server = $c->query('ServerContainer'); @@ -138,7 +149,7 @@ class Application extends App { $server = $this->getContainer()->query('ServerContainer'); $mountProviderCollection = $server->getMountProviderCollection(); $mountProviderCollection->registerProvider($this->getContainer()->query('MountProvider')); - $mountProviderCollection->registerProvider($this->getContainer()->query('ExternalManager')); + $mountProviderCollection->registerProvider($this->getContainer()->query('ExternalMountProvider')); } public function setupPropagation() { |