From 006478d451fdd72dc63c962a5c0572f227dc7eda Mon Sep 17 00:00:00 2001 From: pictuga Date: Mon, 6 Apr 2015 23:13:46 +0800 Subject: [PATCH] 2to3: fix feeds.py string handling Use bytes strings --- morss/feeds.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/morss/feeds.py b/morss/feeds.py index 64dff2f..3f9a51d 100644 --- a/morss/feeds.py +++ b/morss/feeds.py @@ -334,7 +334,7 @@ class FeedListDescriptor(object): class FeedParser(FeedBase): itemsClass = 'FeedItem' mimetype = 'application/xml' - base = '' + base = b'' dic = ('title', 'desc', 'items') def __init__(self, xml=None, tag='atom:feed'): @@ -404,8 +404,8 @@ class FeedParserRSS(FeedParser): itemsClass = 'FeedItemRSS' mimetype = 'application/rss+xml' base = { - 'rdf:rdf': '', - 'channel': ''} + 'rdf:rdf': b'', + 'channel': b''} def get_title(self): return self.xval('rssfake:title|title') @@ -441,8 +441,8 @@ class FeedParserAtom(FeedParser): """ itemsClass = 'FeedItemAtom' mimetype = 'application/atom+xml' - base = {'atom:feed': '', - 'atom03:feed': ''} + base = {'atom:feed': b'', + 'atom03:feed': b''} def get_title(self): return self.xval('atom:title|atom03:title')