From 73ab147f250dabf2672ae707f7e9fa0478809e1c Mon Sep 17 00:00:00 2001 From: Michael Gapczynski Date: Sun, 28 Jul 2013 15:32:48 -0400 Subject: [PATCH] Move check so the variable will never be undefined --- lib/files/cache/scanner.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/files/cache/scanner.php b/lib/files/cache/scanner.php index cb62f2ba310..5588861fe90 100644 --- a/lib/files/cache/scanner.php +++ b/lib/files/cache/scanner.php @@ -96,9 +96,9 @@ class Scanner { // Only update metadata that has changed $newData = array_diff($data, $cacheData); } - } - if (!empty($newData)) { - $this->cache->put($file, $newData); + if (!empty($newData)) { + $this->cache->put($file, $newData); + } } return $data; } -- 2.39.5