diff --git a/backend.php b/backend.php
index 7781828a7..c0b20b1db 100644
--- a/backend.php
+++ b/backend.php
@@ -825,6 +825,9 @@
if (strtoupper($purge_intl) == "DEFAULT")
$purge_intl = 0;
+ if (strtoupper($purge_intl) == "DISABLED")
+ $purge_intl = -1;
+
$result = db_query($link, "UPDATE ttrss_feeds SET
title = '$feed_title', feed_url = '$feed_link',
update_interval = '$upd_intl',
@@ -958,6 +961,9 @@
if ($line["purge_interval"] == "0")
$line["purge_interval"] = "Default";
+ if ($line["purge_interval"] < 0)
+ $line["purge_interval"] = "Disabled";
+
print "
" .
$line["purge_interval"] . " | ";
@@ -977,6 +983,9 @@
if ($line["purge_interval"] == "0")
$line["purge_interval"] = "Default";
+ if ($line["purge_interval"] < 0)
+ $line["purge_interval"] = "Disabled";
+
print "" . $line["purge_interval"] . " | ";
} else {
diff --git a/functions.php b/functions.php
index 4ab9ac7df..7d603e9cb 100644
--- a/functions.php
+++ b/functions.php
@@ -14,7 +14,7 @@
if ($purge_interval == 0) $purge_interval = PURGE_OLD_DAYS;
- if ($purge_interval != 0) {
+ if ($purge_interval > 0) {
if (DB_TYPE == "pgsql") {
db_query($link, "DELETE FROM ttrss_entries WHERE
diff --git a/prefs.js b/prefs.js
index 5c6f7a7f6..b9973fd2e 100644
--- a/prefs.js
+++ b/prefs.js
@@ -466,7 +466,7 @@ function feedEditSave() {
// notify("Saving feed.");
- if (upd_intl < 0) {
+/* if (upd_intl < 0) {
notify("Update interval must be >= 0 (0 = default)");
return;
}
@@ -474,7 +474,7 @@ function feedEditSave() {
if (purge_intl < 0) {
notify("Purge days must be >= 0 (0 = default)");
return;
- }
+ } */
if (link.length == 0) {
notify("Feed link cannot be blank.");