diff options
author | Bjoern Schiessle <schiessle@owncloud.com> | 2014-04-30 16:56:09 +0200 |
---|---|---|
committer | Bjoern Schiessle <schiessle@owncloud.com> | 2014-05-21 13:19:17 +0200 |
commit | 5f403f3e920ea8f6ed5d0441762b3e4f4a9bd38e (patch) | |
tree | 1390f388645003b9d4e5ee3ff5adc63e3dd48b62 /apps/files_sharing/lib/updater.php | |
parent | 319942bccb0f08abd694219b1c7bcf1e71d589c4 (diff) | |
download | nextcloud-server-5f403f3e920ea8f6ed5d0441762b3e4f4a9bd38e.tar.gz nextcloud-server-5f403f3e920ea8f6ed5d0441762b3e4f4a9bd38e.zip |
move the mount point up if a share is mounted to a subfolder and the subfolder no longer exists
Diffstat (limited to 'apps/files_sharing/lib/updater.php')
-rw-r--r-- | apps/files_sharing/lib/updater.php | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/apps/files_sharing/lib/updater.php b/apps/files_sharing/lib/updater.php index 21d67caad9d..5cb2b638e5a 100644 --- a/apps/files_sharing/lib/updater.php +++ b/apps/files_sharing/lib/updater.php @@ -115,11 +115,14 @@ class Shared_Updater { * @param array $params */ static public function deleteHook($params) { - self::correctFolders($params['path']); - $fileInfo = \OC\Files\Filesystem::getFileInfo($params['path']); + $path = $params['path']; + self::correctFolders($path); + + $fileInfo = \OC\Files\Filesystem::getFileInfo($path); + // mark file as deleted so that we can clean up the share table if // the file was deleted successfully - self::$toRemove[$params['path']] = $fileInfo['fileid']; + self::$toRemove[$path] = $fileInfo['fileid']; } /** |