From b55be6fd8fcc5950b16671373a0d0325d9d1dd35 Mon Sep 17 00:00:00 2001 From: Arthur Schiwon Date: Wed, 21 Jun 2023 18:01:49 +0200 Subject: fix: cominbation of small fixes - possible null return - parameter name mismatch in implementation - incomplete unit test Signed-off-by: Arthur Schiwon --- apps/dav/lib/Connector/Sabre/FilesReportPlugin.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'apps/dav/lib/Connector/Sabre') diff --git a/apps/dav/lib/Connector/Sabre/FilesReportPlugin.php b/apps/dav/lib/Connector/Sabre/FilesReportPlugin.php index 4fabe9fdd1c..450fe134772 100644 --- a/apps/dav/lib/Connector/Sabre/FilesReportPlugin.php +++ b/apps/dav/lib/Connector/Sabre/FilesReportPlugin.php @@ -284,9 +284,9 @@ class FilesReportPlugin extends ServerPlugin { * @param array $filterRules * @return array array of unique file id results */ - protected function processFilterRulesForFileIDs($filterRules) { + protected function processFilterRulesForFileIDs(array $filterRules): array { $ns = '{' . $this::NS_OWNCLOUD . '}'; - $resultFileIds = null; + $resultFileIds = []; $circlesIds = []; $favoriteFilter = null; foreach ($filterRules as $filterRule) { @@ -407,7 +407,7 @@ class FilesReportPlugin extends ServerPlugin { * @param array $fileIds file ids * @return Node[] array of Sabre nodes */ - public function findNodesByFileIds($rootNode, $fileIds): array { + public function findNodesByFileIds(Node $rootNode, array $fileIds): array { if (empty($fileIds)) { return []; } -- cgit v1.2.3