diff options
author | wn_ <[email protected]> | 2023-03-05 14:09:20 +0000 |
---|---|---|
committer | wn_ <[email protected]> | 2023-03-05 14:20:19 +0000 |
commit | 7ed4fa4c1dbdd9df552cf6dd28907c6769911a0e (patch) | |
tree | 6307be0437e7ca120975f0393d7245455e059f62 | |
parent | c4b16ca6085f30d69669009dcf75e3cbf8391cb8 (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.
-rwxr-xr-x | classes/pref/feeds.php | 4 |
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'])); |