summaryrefslogtreecommitdiffstats
path: root/lib/filecache.php
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2012-05-11 20:49:19 +0200
committerRobin Appelman <icewind@owncloud.com>2012-05-11 20:49:19 +0200
commitcf3940425ff4b4590bb4e392c58c0ee1aa6f87b0 (patch)
tree24ddeae80aab4b7a41f374f2bef165e76bf79b77 /lib/filecache.php
parent0622fa79ba8f257cf8c48fa495f4e1bc708ca886 (diff)
downloadnextcloud-server-cf3940425ff4b4590bb4e392c58c0ee1aa6f87b0.tar.gz
nextcloud-server-cf3940425ff4b4590bb4e392c58c0ee1aa6f87b0.zip
don't do the initial scanning of the users home folder trough the update system
Diffstat (limited to 'lib/filecache.php')
-rw-r--r--lib/filecache.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/filecache.php b/lib/filecache.php
index 9fa3fbea97d..9ec307cc812 100644
--- a/lib/filecache.php
+++ b/lib/filecache.php
@@ -633,13 +633,16 @@ class OC_FileCache{
}
$mtime=$view->filemtime($path);
$isDir=$view->is_dir($path);
- $path=$root.$path;
+ $fullPath=$root.$path;
$query=OC_DB::prepare('SELECT mtime FROM *PREFIX*fscache WHERE path_hash=?');
- $result=$query->execute(array(md5($path)));
+ $result=$query->execute(array(md5($fullPath)));
if($row=$result->fetchRow()){
$cachedMTime=$row['mtime'];
return ($mtime>$cachedMTime);
}else{//file not in cache, so it has to be updated
+ if($path=='/' or $path==''){//dont auto update the root folder, it will be scanned
+ return false;
+ }
return true;
}
}