summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-05-15 12:13:46 +0200
committerBjoern Schiessle <schiessle@owncloud.com>2014-06-14 10:13:24 +0200
commita900c7aa94ad6527cb3bdf2600b6b1e9e6b497ac (patch)
tree2bb4cc0277076ec22d4d9bb761451cc2f234d8c9
parent1c149da52f7b742b51dcd2b71035506a0a149eaa (diff)
downloadnextcloud-server-a900c7aa94ad6527cb3bdf2600b6b1e9e6b497ac.tar.gz
nextcloud-server-a900c7aa94ad6527cb3bdf2600b6b1e9e6b497ac.zip
Fix removing remote shares
-rw-r--r--apps/files_sharing/lib/external/storage.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/apps/files_sharing/lib/external/storage.php b/apps/files_sharing/lib/external/storage.php
index 2683a6a6902..0e799a0e9e3 100644
--- a/apps/files_sharing/lib/external/storage.php
+++ b/apps/files_sharing/lib/external/storage.php
@@ -88,4 +88,22 @@ class Storage extends \OC\Files\Storage\DAV implements ISharedStorage {
return false;
}
}
+
+ public function unlink($path) {
+ if ($path === '' || $path === false) {
+ $this->manager->removeShare($this->mountPoint);
+ return true;
+ } else {
+ return parent::unlink($path);
+ }
+ }
+
+ public function rmdir($path) {
+ if ($path === '' || $path === false) {
+ $this->manager->removeShare($this->mountPoint);
+ return true;
+ } else {
+ return parent::rmdir($path);
+ }
+ }
}