From f0ffae31a6b95a0876dfa6cf8f9fc97089001c6e Mon Sep 17 00:00:00 2001 From: echel0n Date: Sat, 29 Mar 2014 01:22:08 -0700 Subject: [PATCH] Fixed bug in TVRage API that was effecting python 2.6 users --- lib/tvrage_api/tvrage_api.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/tvrage_api/tvrage_api.py b/lib/tvrage_api/tvrage_api.py index 5a0ea5ac..549ecd8a 100644 --- a/lib/tvrage_api/tvrage_api.py +++ b/lib/tvrage_api/tvrage_api.py @@ -410,7 +410,7 @@ class TVRage: # remove it to avoid errors. Change from SickBeard, from will14m xml = ElementTree.fromstring(src.rstrip("\r")) tree = ElementTree.ElementTree(xml) - for elm in tree.iter(): + for elm in tree.findall('.//*'): elm.tag = robj.sub(lambda m: reDict[m.group(0)], elm.tag) if elm.tag in 'firstaired': @@ -428,7 +428,7 @@ class TVRage: try: xml = ElementTree.fromstring(src.rstrip("\r")) tree = ElementTree.ElementTree(xml) - for elm in tree.iter(): + for elm in tree.findall('.//*'): elm.tag = robj.sub(lambda m: reDict[m.group(0)], elm.tag) if elm.tag in 'firstaired' and elm.text: