summaryrefslogtreecommitdiffstats
path: root/lib/filesystem.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/filesystem.php')
-rw-r--r--lib/filesystem.php13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/filesystem.php b/lib/filesystem.php
index 12905d189f9..b6909f5acdf 100644
--- a/lib/filesystem.php
+++ b/lib/filesystem.php
@@ -298,6 +298,19 @@ class OC_Filesystem{
}
return true;
}
+
+ /**
+ * checks if a file is blacklsited for storage in the filesystem
+ * @param array $data from hook
+ */
+ static public function isBlacklisted($data){
+ $blacklist = array('.htaccess');
+ $filename = strtolower(basename($data['path']));
+ if(in_array($filename,$blacklist)){
+ $data['run'] = false;
+ }
+ }
+
/**
* following functions are equivilent to their php buildin equivilents for arguments/return values.
*/