aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/server.php
diff options
context:
space:
mode:
authorRoeland Douma <rullzer@users.noreply.github.com>2015-09-06 16:56:35 +0200
committerRoeland Douma <rullzer@users.noreply.github.com>2015-09-06 16:56:35 +0200
commit24f5f50b20c4f49bcd602a3c322f2ee2deb0f95b (patch)
treeb5ba1876566dfa1cc39341e8f58e419bc137d722 /lib/private/server.php
parent3642fb701a7fc0caba779de9f5d53bf12c27f5aa (diff)
parentc6314fc699c7316973fa79f75b7d585e620323e9 (diff)
downloadnextcloud-server-24f5f50b20c4f49bcd602a3c322f2ee2deb0f95b.tar.gz
nextcloud-server-24f5f50b20c4f49bcd602a3c322f2ee2deb0f95b.zip
Merge pull request #18742 from owncloud/mimetype-updatedb
Introduce mimetype DB update occ command
Diffstat (limited to 'lib/private/server.php')
-rw-r--r--lib/private/server.php14
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/private/server.php b/lib/private/server.php
index 24674d2e3c7..393c1840973 100644
--- a/lib/private/server.php
+++ b/lib/private/server.php
@@ -470,6 +470,11 @@ class Server extends SimpleContainer implements IServerContainer {
$c->getURLGenerator(),
\OC::$configDir);
});
+ $this->registerService('MimeTypeLoader', function(Server $c) {
+ return new \OC\Files\Type\Loader(
+ $c->getDatabaseConnection()
+ );
+ });
$this->registerService('CapabilitiesManager', function (Server $c) {
$manager = new \OC\CapabilitiesManager();
$manager->registerCapability(function() use ($c) {
@@ -1011,6 +1016,15 @@ class Server extends SimpleContainer implements IServerContainer {
}
/**
+ * Get the MimeTypeLoader
+ *
+ * @return \OCP\Files\IMimeTypeLoader
+ */
+ public function getMimeTypeLoader() {
+ return $this->query('MimeTypeLoader');
+ }
+
+ /**
* Get the manager of all the capabilities
*
* @return \OC\CapabilitiesManager