diff options
author | Robin Appelman <icewind@owncloud.com> | 2015-04-13 17:09:18 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2015-04-13 17:10:05 +0200 |
commit | f605c985311fc652d1744704061af38f3ac62919 (patch) | |
tree | cd7c7d39d44977522cab32ebe5dd5add0f72b9ab /apps/files_sharing/lib/sharedstorage.php | |
parent | 01da6be4d6301cceb3a0c04106aacc7178783353 (diff) | |
download | nextcloud-server-f605c985311fc652d1744704061af38f3ac62919.tar.gz nextcloud-server-f605c985311fc652d1744704061af38f3ac62919.zip |
Fix cross storage move with shared storages
Diffstat (limited to 'apps/files_sharing/lib/sharedstorage.php')
-rw-r--r-- | apps/files_sharing/lib/sharedstorage.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php index 6e3abb1f56c..c2253fcaa3c 100644 --- a/apps/files_sharing/lib/sharedstorage.php +++ b/apps/files_sharing/lib/sharedstorage.php @@ -327,7 +327,10 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage { $targetFilename = basename($relPath2); list($user2, $path2) = \OCA\Files_Sharing\Helper::getUidAndFilename(dirname($relPath2)); $rootView = new \OC\Files\View(''); - return $rootView->rename('/' . $user1 . '/files/' . $path1, '/' . $user2 . '/files/' . $path2 . '/' . $targetFilename); + $rootView->getUpdater()->disable(); // dont update the cache here + $result = $rootView->rename('/' . $user1 . '/files/' . $path1, '/' . $user2 . '/files/' . $path2 . '/' . $targetFilename); + $rootView->getUpdater()->enable(); + return $result; } public function copy($path1, $path2) { |