zs

Zeitungsschau rss to email converter
git clone git://r-36.net/zs
Log | Files | Refs | LICENSE

commit 05d5993acdbe7f3d6de29e18d5f0349e935cf2a8
parent 285512021b13bf125d11d4d4504f78732445dba8
Author: Christoph Lohmann <20h@r-36.net>
Date:   Sun,  9 Mar 2014 21:33:59 +0100

Damn auto conversion of types.

Diffstat:
feeddb.py | 10+++++-----
1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/feeddb.py b/feeddb.py @@ -100,8 +100,11 @@ class feeddb(object): def unpause(self, uri): self.setfeedval(uri, "pause", False) + def listfeeds(self): + return list(self.feeds.keys()) + def addfeed(self, uri, email=None): - if not uri in self.feeds: + if not uri in self.listfeeds(): feed = {} if email == None: feed["toemail"] = self.cfg["email"] @@ -113,12 +116,9 @@ class feeddb(object): self.writefeed(uri, feed) def delfeed(self, uri): - if uri in self.feeds: + if uri in self.listfeeds(): del self.feeds[uri] - def listfeeds(self): - return list(self.feeds.keys()) - def listactivefeeds(self): rfeeds = [] for f in self.feeds: