aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRobin Appelman <icewind1991@gmail.com>2011-10-22 14:10:51 +0200
committerRobin Appelman <icewind@owncloud.com>2012-02-21 20:48:47 +0100
commit82394f9527817673f3ecbf7e5fd1d4857f0f3fe1 (patch)
tree245b72bf2c08d234ba83ee27cf4ac4a2e38b407d /lib
parent3d67cd51c2f42029435343004b3ebe608bcba375 (diff)
downloadnextcloud-server-82394f9527817673f3ecbf7e5fd1d4857f0f3fe1.tar.gz
nextcloud-server-82394f9527817673f3ecbf7e5fd1d4857f0f3fe1.zip
add option to dissable fileproxies
Diffstat (limited to 'lib')
-rw-r--r--lib/fileproxy.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/fileproxy.php b/lib/fileproxy.php
index 796fd95cb38..46fc2f49c50 100644
--- a/lib/fileproxy.php
+++ b/lib/fileproxy.php
@@ -39,6 +39,7 @@
class OC_FileProxy{
private static $proxies=array();
+ public static $enabled=true;
/**
* check if this proxy implments a specific proxy operation
@@ -84,6 +85,9 @@ class OC_FileProxy{
}
public static function runPreProxies($operation,&$filepath,&$filepath2=null){
+ if(!self::$enabled){
+ return true;
+ }
$proxies=self::getProxies($operation,false);
$operation='pre'.$operation;
foreach($proxies as $proxy){
@@ -101,6 +105,9 @@ class OC_FileProxy{
}
public static function runPostProxies($operation,$path,$result){
+ if(!self::$enabled){
+ return $result;
+ }
$proxies=self::getProxies($operation,true);
$operation='post'.$operation;
foreach($proxies as $proxy){