From 387be374270dc1ac3669325fee60d35889a85b6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20Sch=C3=B6nebeck?= Date: Fri, 15 Mar 2013 12:11:42 +0100 Subject: [PATCH] Filter display of blacklisted files Blacklisted files like ".htaccess" and ".git" should not only be blacklisted for upload and rename, but they should also not be displayed in the directory listings. I needed this personally to hide ".git" folders in shared folders. Its also a simple implementation of feature requests like http://forum.owncloud.org/viewtopic.php?f=4&t=3279 and http://forum.owncloud.org/viewtopic.php?f=3&t=5708 --- lib/files/cache/scanner.php | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/files/cache/scanner.php b/lib/files/cache/scanner.php index 88f208547f..f285f3bed1 100644 --- a/lib/files/cache/scanner.php +++ b/lib/files/cache/scanner.php @@ -151,6 +151,7 @@ class Scanner { private function isIgnoredFile($file) { if ($file === '.' || $file === '..' || pathinfo($file, PATHINFO_EXTENSION) === 'part' + || \OC\Files\Filesystem::isFileBlacklisted($file) ) { return true; }