summaryrefslogtreecommitdiff
path: root/classes/pref/feeds.php
diff options
context:
space:
mode:
authorwn_ <[email protected]>2023-03-05 14:09:20 +0000
committerwn_ <[email protected]>2023-03-05 14:20:19 +0000
commit7ed4fa4c1dbdd9df552cf6dd28907c6769911a0e (patch)
tree6307be0437e7ca120975f0393d7245455e059f62 /classes/pref/feeds.php
parentc4b16ca6085f30d69669009dcf75e3cbf8391cb8 (diff)
Tweak to appease PHPStan in 'Pref_Feeds::_makefeedtree()'.
PHPStan flagged the 'count()' below this with: Comparison operation '>' between 0 and 0 is always false.
Diffstat (limited to 'classes/pref/feeds.php')
-rwxr-xr-xclasses/pref/feeds.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/classes/pref/feeds.php b/classes/pref/feeds.php
index 679eb12e9..d8b2ba01a 100755
--- a/classes/pref/feeds.php
+++ b/classes/pref/feeds.php
@@ -267,7 +267,7 @@ class Pref_Feeds extends Handler_Protected {
}
foreach ($feeds_obj->find_many() as $feed) {
- array_push($cat['items'], [
+ $cat['items'][] = [
'id' => 'FEED:' . $feed->id,
'bare_id' => (int) $feed->id,
'auxcounter' => -1,
@@ -279,7 +279,7 @@ class Pref_Feeds extends Handler_Protected {
'unread' => -1,
'type' => 'feed',
'updates_disabled' => (int)($feed->update_interval < 0),
- ]);
+ ];
}
$cat['param'] = sprintf(_ngettext('(%d feed)', '(%d feeds)', count($cat['items'])), count($cat['items']));