Commit 8421c78b authored by Dan Pascu's avatar Dan Pascu

Explicitly check for None

parent c34bb8bf
......@@ -97,7 +97,7 @@ class IconManager(object):
data = file(filename).read()
except (IOError, OSError):
data = None
if pixmap.loadFromData(data):
if data is not None and pixmap.loadFromData(data):
icon = QIcon(pixmap)
icon.filename = filename
icon.content = data
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment