make phpstan happy
This commit is contained in:
parent
3545d3ba83
commit
42bc1620b8
|
@ -551,6 +551,7 @@ class API extends Handler {
|
|||
if (!implements_interface($feed['sender'], 'IVirtualFeed'))
|
||||
continue;
|
||||
|
||||
/** @var IVirtualFeed $feed['sender'] */
|
||||
$unread = $feed['sender']->get_unread($feed['id']);
|
||||
|
||||
if ($unread || !$unread_only) {
|
||||
|
@ -697,9 +698,12 @@ class API extends Handler {
|
|||
"skip_first_id_check" => $skip_first_id_check
|
||||
);
|
||||
|
||||
$qfh_ret = [];
|
||||
|
||||
if (!$is_cat && is_numeric($feed_id) && $feed_id < PLUGIN_FEED_BASE_INDEX && $feed_id > LABEL_BASE_INDEX) {
|
||||
/** @var IVirtualFeed|false $handler */
|
||||
$pfeed_id = PluginHost::feed_to_pfeed_id($feed_id);
|
||||
|
||||
/** @var IVirtualFeed|false $handler */
|
||||
$handler = PluginHost::getInstance()->get_feed_handler($pfeed_id);
|
||||
|
||||
if ($handler) {
|
||||
|
|
|
@ -667,7 +667,7 @@ class Feeds extends Handler_Protected {
|
|||
}
|
||||
|
||||
Debug::set_enabled(true);
|
||||
Debug::set_loglevel(Debug::map_loglevel($xdebug));
|
||||
Debug::set_loglevel((int)Debug::map_loglevel($xdebug));
|
||||
|
||||
$feed_id = (int)$_REQUEST["feed_id"];
|
||||
$do_update = ($_REQUEST["action"] ?? "") == "do_update";
|
||||
|
@ -969,6 +969,7 @@ class Feeds extends Handler_Protected {
|
|||
$feed_id = PluginHost::feed_to_pfeed_id($feed);
|
||||
$handler = PluginHost::getInstance()->get_feed_handler($feed_id);
|
||||
if (implements_interface($handler, 'IVirtualFeed')) {
|
||||
/** @var IVirtualFeed $handler */
|
||||
return $handler->get_unread($feed_id);
|
||||
} else {
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue