Skip to content
Snippets Groups Projects
Commit eebc393f authored by Daniel Brötzmann's avatar Daniel Brötzmann
Browse files

Don't fail hard if we cannot get icon

parent 1bc90e22
No related branches found
No related tags found
No related merge requests found
......@@ -222,6 +222,9 @@ def load_icon(icon_name, widget=None, size=16, pixbuf=False,
try:
iconinfo = _icon_theme.lookup_icon_for_scale(
icon_name, size, scale, flags)
if iconinfo is None:
log.info('No icon found for %s', icon_name)
return
if pixbuf:
return iconinfo.load_icon()
return iconinfo.load_surface(None)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment