mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-16 00:55:57 +00:00
api, also hide uncategorized if empty
This commit is contained in:
@@ -727,7 +727,7 @@ class API extends Handler {
|
||||
|
||||
}
|
||||
|
||||
// only works for labels for the time being
|
||||
// only works for labels or uncategorized for the time being
|
||||
private function isCategoryEmpty($id) {
|
||||
|
||||
if ($id == -2) {
|
||||
@@ -736,6 +736,12 @@ class API extends Handler {
|
||||
|
||||
return db_fetch_result($result, 0, "count") == 0;
|
||||
|
||||
} else if ($id == 0) {
|
||||
$result = db_query($this->link, "SELECT COUNT(*) AS count FROM ttrss_feeds
|
||||
WHERE cat_id IS NULL AND owner_uid = " . $_SESSION["uid"]);
|
||||
|
||||
return db_fetch_result($result, 0, "count") == 0;
|
||||
|
||||
}
|
||||
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user