summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing
diff options
context:
space:
mode:
authorBrice Maron <brice@bmaron.net>2012-05-07 22:37:18 +0000
committerBrice Maron <brice@bmaron.net>2012-05-07 22:37:18 +0000
commit010b97febdbabc9b9100b5f98394e427922129da (patch)
tree36ddb7f61e4dfbbfeeb966dc8cffebab767b59ad /apps/files_sharing
parent9921ca11b56637bdb6d1e1c2b6bb7c932cf3cd55 (diff)
downloadnextcloud-server-010b97febdbabc9b9100b5f98394e427922129da.tar.gz
nextcloud-server-010b97febdbabc9b9100b5f98394e427922129da.zip
Avoid touch operation when unshare public link
Diffstat (limited to 'apps/files_sharing')
-rwxr-xr-xapps/files_sharing/lib_share.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/files_sharing/lib_share.php b/apps/files_sharing/lib_share.php
index c2340bdc181..b6346b97cf8 100755
--- a/apps/files_sharing/lib_share.php
+++ b/apps/files_sharing/lib_share.php
@@ -377,8 +377,10 @@ class OC_Share {
$query = OCP\DB::prepare("DELETE FROM *PREFIX*sharing WHERE SUBSTR(source, 1, ?) = ? AND uid_owner = ? AND uid_shared_with ".self::getUsersAndGroups($uid_shared_with));
$query->execute(array(strlen($source), $source, OCP\USER::getUser()));
// Update mtime of shared folder to invoke a file cache rescan
- $sharedFolder = '/'.$uid_shared_with.'/files/Shared';
- OC_Filesystem::getStorage($sharedFolder)->touch($sharedFolder);
+ if ($uid_shared_with != self::PUBLICLINK) {
+ $sharedFolder = '/'.$uid_shared_with.'/files/Shared';
+ OC_Filesystem::getStorage($sharedFolder)->touch($sharedFolder);
+ }
}
/**