aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/legacy
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/legacy')
-rw-r--r--lib/private/legacy/OC_Files.php2
-rw-r--r--lib/private/legacy/OC_Helper.php2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/legacy/OC_Files.php b/lib/private/legacy/OC_Files.php
index 1b2f83941c8..7e6d8632642 100644
--- a/lib/private/legacy/OC_Files.php
+++ b/lib/private/legacy/OC_Files.php
@@ -104,7 +104,7 @@ class OC_Files {
* return the content of a file or return a zip file containing multiple files
*
* @param string $dir
- * @param string $files ; separated list of files to download
+ * @param string|array $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 = null) {
diff --git a/lib/private/legacy/OC_Helper.php b/lib/private/legacy/OC_Helper.php
index 9a12bd50e0e..7c9810e9081 100644
--- a/lib/private/legacy/OC_Helper.php
+++ b/lib/private/legacy/OC_Helper.php
@@ -138,7 +138,7 @@ class OC_Helper {
$bytes = (float)$str;
- if (preg_match('#([kmgtp]?b?)$#si', $str, $matches) && !empty($bytes_array[$matches[1]])) {
+ if (preg_match('#([kmgtp]?b?)$#si', $str, $matches) && isset($bytes_array[$matches[1]])) {
$bytes *= $bytes_array[$matches[1]];
} else {
return false;