summaryrefslogtreecommitdiff
path: root/classes/pref
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2013-06-26 02:17:49 +0400
committerAndrew Dolgov <[email protected]>2013-06-26 02:17:49 +0400
commitafa1a260d0c47ddb44225786fb3ed892a0a0b428 (patch)
treed6f799814cdbbe4f5c932b198e9e4431e0e293cf /classes/pref
parent44727c79ad0593982b817554412fc5313e36e2fb (diff)
fix inverse status not being set correctly for filters when creating
them fix inverse rules not being saved/restored properly through opml
Diffstat (limited to 'classes/pref')
-rw-r--r--classes/pref/filters.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/classes/pref/filters.php b/classes/pref/filters.php
index bcc7b5aec..6a70e622c 100644
--- a/classes/pref/filters.php
+++ b/classes/pref/filters.php
@@ -585,14 +585,15 @@ class Pref_Filters extends Handler_Protected {
$enabled = checkbox_to_sql_bool($_REQUEST["enabled"]);
$match_any_rule = checkbox_to_sql_bool($_REQUEST["match_any_rule"]);
$title = $this->dbh->escape_string($_REQUEST["title"]);
+ $inverse = checkbox_to_sql_bool($_REQUEST["inverse"]);
$this->dbh->query("BEGIN");
/* create base filter */
$result = $this->dbh->query("INSERT INTO ttrss_filters2
- (owner_uid, match_any_rule, enabled, title) VALUES
- (".$_SESSION["uid"].",$match_any_rule,$enabled, '$title')");
+ (owner_uid, match_any_rule, enabled, title, inverse) VALUES
+ (".$_SESSION["uid"].",$match_any_rule,$enabled, '$title', $inverse)");
$result = $this->dbh->query("SELECT MAX(id) AS id FROM ttrss_filters2
WHERE owner_uid = ".$_SESSION["uid"]);