diff --git a/comicbookinfo.py b/comicbookinfo.py index d61cb28..469a9d7 100644 --- a/comicbookinfo.py +++ b/comicbookinfo.py @@ -115,7 +115,7 @@ class ComicBookInfo: #helper func def toInt(s): i = None - if type(s) == str or type(s) == int: + if type(s) in [ str, unicode, int ]: try: i = int(s) except ValueError: diff --git a/taggerwindow.py b/taggerwindow.py index 55f0384..9286d8b 100644 --- a/taggerwindow.py +++ b/taggerwindow.py @@ -1573,8 +1573,7 @@ class TaggerWindow( QtGui.QMainWindow): if cv_md is None: match_results.fetchDataFailures.append(ca.path) - if cv_md is not None: - + if cv_md is not None: md.overlay( cv_md ) if not ca.writeMetadata( md, self.save_data_style ):