diff options
author | Roeland Jago Douma <rullzer@owncloud.com> | 2016-01-27 14:48:52 +0100 |
---|---|---|
committer | Roeland Jago Douma <rullzer@owncloud.com> | 2016-01-27 22:04:37 +0100 |
commit | f2e70441e42a17b27248b93a05b0008717b124b1 (patch) | |
tree | e3504e90449a663f31089f6efe0d46a86047457e /lib | |
parent | 357b271cb48c71de22a9de594fba4b3e265cadeb (diff) | |
download | nextcloud-server-f2e70441e42a17b27248b93a05b0008717b124b1.tar.gz nextcloud-server-f2e70441e42a17b27248b93a05b0008717b124b1.zip |
[Share 2.0] Add getShareManager to OCP\IServerContainer
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/appframework/dependencyinjection/dicontainer.php | 4 | ||||
-rw-r--r-- | lib/private/server.php | 3 | ||||
-rw-r--r-- | lib/public/iservercontainer.php | 8 |
3 files changed, 13 insertions, 2 deletions
diff --git a/lib/private/appframework/dependencyinjection/dicontainer.php b/lib/private/appframework/dependencyinjection/dicontainer.php index 175d6c747e4..61a04482431 100644 --- a/lib/private/appframework/dependencyinjection/dicontainer.php +++ b/lib/private/appframework/dependencyinjection/dicontainer.php @@ -227,6 +227,10 @@ class DIContainer extends SimpleContainer implements IAppContainer { return $this->getServer()->getSecureRandom(); }); + $this->registerService('OCP\\Share\\IManager', function($c) { + return $this->getServer()->getShareManager(); + }); + $this->registerService('OCP\\SystemTag\\ISystemTagManager', function() { return $this->getServer()->getSystemTagManager(); }); diff --git a/lib/private/server.php b/lib/private/server.php index 4f731300baf..d453a42d3a0 100644 --- a/lib/private/server.php +++ b/lib/private/server.php @@ -1256,9 +1256,8 @@ class Server extends ServerContainer implements IServerContainer { return \OC_Mount_Config::$app->getContainer()->query('OCA\\Files_External\\Service\\UserStoragesService'); } - /** - * @return \OC\Share20\Manager + * @return \OCP\Share\IManager */ public function getShareManager() { return $this->query('ShareManager'); diff --git a/lib/public/iservercontainer.php b/lib/public/iservercontainer.php index e21c9fb8e4b..ce1364cc4ea 100644 --- a/lib/public/iservercontainer.php +++ b/lib/public/iservercontainer.php @@ -504,4 +504,12 @@ interface IServerContainer { * @since 9.0.0 */ public function getSystemTagObjectMapper(); + + /** + * Returns the share manager + * + * @return \OCP\Share\IManager + * @since 9.0.0 + */ + public function getShareManager(); } |