Avoid updating feed based on user pref DEFAULT_UPDATE_INTERVAL if it is set to -1 (no update)

This commit is contained in:
all 2013-03-30 09:43:37 +01:00
parent 05e62b6726
commit bca1cfbb95
1 changed files with 2 additions and 0 deletions

View File

@ -77,6 +77,7 @@
if (DB_TYPE == "pgsql") {
$update_limit_qpart = "AND ((
ttrss_feeds.update_interval = 0
AND ttrss_user_prefs.value > 0
AND ttrss_feeds.last_updated < NOW() - CAST((ttrss_user_prefs.value || ' minutes') AS INTERVAL)
) OR (
ttrss_feeds.update_interval > 0
@ -86,6 +87,7 @@
} else {
$update_limit_qpart = "AND ((
ttrss_feeds.update_interval = 0
AND ttrss_user_prefs.value > 0
AND ttrss_feeds.last_updated < DATE_SUB(NOW(), INTERVAL CONVERT(ttrss_user_prefs.value, SIGNED INTEGER) MINUTE)
) OR (
ttrss_feeds.update_interval > 0