summaryrefslogtreecommitdiffstats
path: root/apps/dav
diff options
context:
space:
mode:
authorRoeland Douma <rullzer@users.noreply.github.com>2016-07-20 20:08:22 +0200
committerGitHub <noreply@github.com>2016-07-20 20:08:22 +0200
commit26cf51403e51c8753b9075df76ebc9ea90901851 (patch)
tree67af2da433c843f0392959e6334f016f7a2027c3 /apps/dav
parentffc345b141d73b15a2dfe9830dea70cdb8c26ebe (diff)
parente795f7b1066782205f2c5b5482dc9535088d8d98 (diff)
downloadnextcloud-server-26cf51403e51c8753b9075df76ebc9ea90901851.tar.gz
nextcloud-server-26cf51403e51c8753b9075df76ebc9ea90901851.zip
Merge pull request #464 from nextcloud/master-change-load-order
[master] Change load order of auth backends so that we can throw an exception …
Diffstat (limited to 'apps/dav')
-rw-r--r--apps/dav/lib/Server.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/dav/lib/Server.php b/apps/dav/lib/Server.php
index 0715d39049c..73a07072d3c 100644
--- a/apps/dav/lib/Server.php
+++ b/apps/dav/lib/Server.php
@@ -72,13 +72,16 @@ class Server {
$this->server->setBaseUri($this->baseUri);
$this->server->addPlugin(new BlockLegacyClientPlugin(\OC::$server->getConfig()));
- $authPlugin = new Plugin($authBackend, 'ownCloud');
+ $authPlugin = new Plugin();
$this->server->addPlugin($authPlugin);
// allow setup of additional auth backends
$event = new SabrePluginEvent($this->server);
$dispatcher->dispatch('OCA\DAV\Connector\Sabre::authInit', $event);
+ // because we are throwing exceptions this plugin has to be the last one
+ $authPlugin->addBackend($authBackend);
+
// debugging
if(\OC::$server->getConfig()->getSystemValue('debug', false)) {
$this->server->addPlugin(new \Sabre\DAV\Browser\Plugin());