summaryrefslogtreecommitdiffstats
path: root/lib/private/legacy/files.php
diff options
context:
space:
mode:
authorPiotr Filiciak <piotr@filiciak.pl>2016-05-23 15:17:00 +0200
committerPiotr Filiciak <piotr@filiciak.pl>2016-05-23 15:17:00 +0200
commit6577bbe887840889e16634b9bf1c4ce247ec265e (patch)
tree97f8fd1f8e846a06fd62f48de81c49d5a6ae64e9 /lib/private/legacy/files.php
parent9999e05660637c77947c71656d2f03d841e19ab9 (diff)
downloadnextcloud-server-6577bbe887840889e16634b9bf1c4ce247ec265e.tar.gz
nextcloud-server-6577bbe887840889e16634b9bf1c4ce247ec265e.zip
Code style and doc fix
Diffstat (limited to 'lib/private/legacy/files.php')
-rw-r--r--lib/private/legacy/files.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/private/legacy/files.php b/lib/private/legacy/files.php
index 6327a0895e6..ad5ba6d94ae 100644
--- a/lib/private/legacy/files.php
+++ b/lib/private/legacy/files.php
@@ -51,16 +51,16 @@ class OC_Files {
const UPLOAD_MIN_LIMIT_BYTES = 1048576; // 1 MiB
- private static $MULTIPART_BOUNDARY = '';
+ private static $multipartBoundary = '';
/**
* @return string
*/
private static function getBoundary() {
- if (empty(self::$MULTIPART_BOUNDARY)) {
- self::$MULTIPART_BOUNDARY = md5(mt_rand());
+ if (empty(self::$multipartBoundary)) {
+ self::$multipartBoundary = md5(mt_rand());
}
- return self::$MULTIPART_BOUNDARY;
+ return self::$multipartBoundary;
}
/**
@@ -101,7 +101,7 @@ class OC_Files {
* @param string $files ; separated list of files to download
* @param array $params ; 'head' boolean to only send header of the request ; 'range' http range header
*/
- public static function get($dir, $files, $params = array( 'head' => false )) {
+ public static function get($dir, $files, $params = null) {
$view = \OC\Files\Filesystem::getView();
$getType = self::FILE;
@@ -115,7 +115,7 @@ class OC_Files {
if (!is_array($files)) {
$filename = $dir . '/' . $files;
if (!$view->is_dir($filename)) {
- self::getSingleFile($view, $dir, $files, $params);
+ self::getSingleFile($view, $dir, $files, is_null($params) ? array() : $params);
return;
}
}