From 9b8ca9ad1f3df5d32df241d8848c8dc92c9a1fc2 Mon Sep 17 00:00:00 2001 From: Carl Schwan Date: Thu, 18 Aug 2022 10:47:49 +0200 Subject: Move findBinaryFinder and isFunctionEnabled away from OC_Helper findBinaryFinder is now a service that is still private but with some minor optimization (remove the hasKey check). isFunctionEnabled is now in OCP\Util Both function are still keep but all internal usage in nextcloud/server were migrated to the new usage, so that we can remove it in 26 Signed-off-by: Carl Schwan --- lib/private/LargeFileHelper.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/private/LargeFileHelper.php') diff --git a/lib/private/LargeFileHelper.php b/lib/private/LargeFileHelper.php index e2984b4bacf..82b3c5ae760 100755 --- a/lib/private/LargeFileHelper.php +++ b/lib/private/LargeFileHelper.php @@ -147,7 +147,7 @@ class LargeFileHelper { * null on failure. */ public function getFileSizeViaExec($filename) { - if (\OC_Helper::is_function_enabled('exec')) { + if (\OCP\Util::isFunctionEnabled('exec')) { $os = strtolower(php_uname('s')); $arg = escapeshellarg($filename); $result = null; @@ -195,7 +195,7 @@ class LargeFileHelper { $result = - 1; } if ($result < 0) { - if (\OC_Helper::is_function_enabled('exec')) { + if (\OCP\Util::isFunctionEnabled('exec')) { $os = strtolower(php_uname('s')); if (strpos($os, 'linux') !== false) { return $this->exec('stat -c %Y ' . escapeshellarg($fullPath)); -- cgit v1.2.3