aboutsummaryrefslogtreecommitdiffstats
path: root/lib/files/cache/scanner.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/files/cache/scanner.php')
-rw-r--r--lib/files/cache/scanner.php9
1 files changed, 3 insertions, 6 deletions
diff --git a/lib/files/cache/scanner.php b/lib/files/cache/scanner.php
index 4eaea947e51..f019d4fc608 100644
--- a/lib/files/cache/scanner.php
+++ b/lib/files/cache/scanner.php
@@ -62,7 +62,7 @@ class Scanner {
* @return array with metadata of the scanned file
*/
public function scanFile($file, $checkExisting = false) {
- if (!$this->isIgnoredFile($file)) {
+ if (!self::isIgnoredFile($file)) {
\OC_Hook::emit('\OC\Files\Cache\Scanner', 'scan_file', array('path' => $file, 'storage' => $this->storageId));
$data = $this->getData($file);
if ($data) {
@@ -90,7 +90,6 @@ class Scanner {
}
return $data;
}
- \OCP\Util::writeLog('scanner', 'Ignoring '.$file.' and not triggering scan_file hook.', \OCP\Util::DEBUG);
return null;
}
@@ -155,9 +154,7 @@ class Scanner {
* @return boolean
*/
private function isIgnoredDir($dir) {
- if ($dir === '.' || $dir === '..'
- || \OC\Files\Filesystem::isFileBlacklisted($file)
- ) {
+ if ($dir === '.' || $dir === '..') {
return true;
}
return false;
@@ -169,7 +166,7 @@ class Scanner {
* @param String $file
* @return boolean
*/
- private function isIgnoredFile($file) {
+ public static function isIgnoredFile($file) {
if (pathinfo($file, PATHINFO_EXTENSION) === 'part'
|| \OC\Files\Filesystem::isFileBlacklisted($file)
) {