add hidden tunable _DISABLE_INACTIVE_FEEDS
This commit is contained in:
parent
dbfb3f3c8d
commit
34899cf9e8
1 changed files with 7 additions and 2 deletions
|
@ -1259,6 +1259,8 @@ class Pref_Feeds extends Handler_Protected {
|
|||
$interval_qpart = "DATE_SUB(NOW(), INTERVAL 3 MONTH)";
|
||||
}
|
||||
|
||||
// could be performance-intensive and prevent feeds pref-panel from showing
|
||||
if (!defined('_DISABLE_INACTIVE_FEEDS') || !_DISABLE_INACTIVE_FEEDS) {
|
||||
$result = $this->dbh->query("SELECT COUNT(*) AS num_inactive FROM ttrss_feeds WHERE
|
||||
(SELECT MAX(updated) FROM ttrss_entries, ttrss_user_entries WHERE
|
||||
ttrss_entries.id = ref_id AND
|
||||
|
@ -1266,6 +1268,9 @@ class Pref_Feeds extends Handler_Protected {
|
|||
ttrss_feeds.owner_uid = ".$_SESSION["uid"]);
|
||||
|
||||
$num_inactive = $this->dbh->fetch_result($result, 0, "num_inactive");
|
||||
} else {
|
||||
$num_inactive = 0;
|
||||
}
|
||||
|
||||
if ($num_inactive > 0) {
|
||||
$inactive_button = "<button dojoType=\"dijit.form.Button\"
|
||||
|
|
Loading…
Reference in a new issue