From: Thomas Müller Date: Mon, 5 Aug 2013 11:51:45 +0000 (+0200) Subject: use isset to prevent undefined index X-Git-Tag: v5.0.10~15 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=d8b14ed47af4ebb3463c3daacd560c32dc853478;p=nextcloud-server.git use isset to prevent undefined index --- diff --git a/lib/files/cache/scanner.php b/lib/files/cache/scanner.php index 5588861fe90..54f5d79eca7 100644 --- a/lib/files/cache/scanner.php +++ b/lib/files/cache/scanner.php @@ -85,7 +85,7 @@ class Scanner { $newData = $data; if ($reuseExisting and $cacheData = $this->cache->get($file)) { // only reuse data if the file hasn't explicitly changed - if ($data['mtime'] === $cacheData['mtime']) { + if (isset($data['mtime']) && isset($cacheData['mtime']) && $data['mtime'] === $cacheData['mtime']) { if (($reuseExisting & self::REUSE_SIZE) && ($data['size'] === -1)) { $data['size'] = $cacheData['size']; }