From 75efde84396a4dbdf6d5b90101e8b9aa8d402b2a Mon Sep 17 00:00:00 2001 From: Andrew Resch Date: Wed, 4 Feb 2009 06:17:09 +0000 Subject: [PATCH] Fix filtering on trackers --- deluge/core/filtermanager.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/deluge/core/filtermanager.py b/deluge/core/filtermanager.py index cf58d68eb..9538f7d04 100644 --- a/deluge/core/filtermanager.py +++ b/deluge/core/filtermanager.py @@ -107,7 +107,10 @@ class FilterManager(component.Component): return torrent_ids #special purpose: state=Active. - filter_dict["state"] = list(filter_dict["state"]) + if "state" in filter_dict: + # We need to make sure this is a list for the logic below + filter_dict["state"] = list(filter_dict["state"]) + if "state" in filter_dict and "Active" in filter_dict["state"]: filter_dict["state"].remove("Active") if not filter_dict["state"]: