diff options
author | Florian Pritz <bluewind@xinu.at> | 2011-09-22 19:24:32 +0200 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2011-09-24 18:41:47 +0200 |
commit | 8648e3c43c26da898c17798f89d60c9505d149b3 (patch) | |
tree | 34e10780eca9ec004900163f958f79192a0f226c /lib/filesystem.php | |
parent | 9c550e8e9f52efa9c117ef1b577386e555010547 (diff) | |
download | nextcloud-server-8648e3c43c26da898c17798f89d60c9505d149b3.tar.gz nextcloud-server-8648e3c43c26da898c17798f89d60c9505d149b3.zip |
only call error_log() if DEBUG is true
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'lib/filesystem.php')
-rw-r--r-- | lib/filesystem.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/filesystem.php b/lib/filesystem.php index 76032fae204..f242a1b158e 100644 --- a/lib/filesystem.php +++ b/lib/filesystem.php @@ -286,7 +286,7 @@ class OC_Filesystem{ return self::basicOperation('file_get_contents',$path,array('read')); } static public function file_put_contents($path,$data){ - error_log($data); + if(defined("DEBUG") && DEBUG) {error_log($data);} return self::basicOperation('file_put_contents',$path,array('create','write'),$data); } static public function unlink($path){ @@ -393,7 +393,7 @@ class OC_Filesystem{ } } static public function fromUploadedFile($tmpFile,$path){ - error_log('upload'); + if(defined("DEBUG") && DEBUG) {error_log('upload');} if(OC_FileProxy::runPreProxies('fromUploadedFile',$tmpFile,$path) and self::canWrite($path) and $storage=self::getStorage($path)){ $run=true; $exists=self::file_exists($path); @@ -403,7 +403,7 @@ class OC_Filesystem{ if($run){ OC_Hook::emit( 'OC_Filesystem', 'write', array( 'path' => $path, 'run' => &$run)); } - error_log('upload2'); + if(defined("DEBUG") && DEBUG) {error_log('upload2');} if($run){ $result=$storage->fromUploadedFile($tmpFile,self::getInternalPath($path)); if(!$exists){ |