From 115724622fa32e1b7981e378e87ccfb770450cb1 Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Sun, 23 Apr 2023 11:58:15 +0200 Subject: PHPStan Level 7 for ten more files (#5327) * PHPStan Level 7 for nine more files * Minor syntax * One more --- app/Services/ImportService.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'app/Services/ImportService.php') diff --git a/app/Services/ImportService.php b/app/Services/ImportService.php index 3707e4c5e..e5d558233 100644 --- a/app/Services/ImportService.php +++ b/app/Services/ImportService.php @@ -56,7 +56,7 @@ class FreshRSS_Import_Service { // Get the categories by names so we can use this array to retrieve // existing categories later. - $categories = $this->catDAO->listCategories(false); + $categories = $this->catDAO->listCategories(false) ?: []; $categories_by_names = []; foreach ($categories as $category) { $categories_by_names[$category->name()] = $category; @@ -180,7 +180,7 @@ class FreshRSS_Import_Service { if (isset($feed_elt['frss:filtersActionRead'])) { $feed->_filtersAction( 'read', - preg_split('/[\n\r]+/', $feed_elt['frss:filtersActionRead']) + preg_split('/[\n\r]+/', $feed_elt['frss:filtersActionRead']) ?: [] ); } -- cgit v1.2.3