Skip to content

Commit

Permalink
fix listitem callback issue
Browse files Browse the repository at this point in the history
  • Loading branch information
willforde committed Apr 8, 2018
1 parent 842fbb8 commit d22fa44
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions script.module.codequick/lib/codequick/listing.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,7 @@ def local_thumb(self, image):
:param image: Filename of the image.
:type image: str or unicode
"""
# Here we can't be sure if 'image' only contains ascii characters
# So ensure_native_str is needed
# Here we can't be sure if 'image' only contains ascii characters, so ensure_native_str is needed
self.raw_dict["thumb"] = local_image.format(ensure_native_str(image))

def global_thumb(self, image):
Expand Down Expand Up @@ -596,13 +595,11 @@ def _close(self):
self.listitem.setProperty("folder", str(callback.route.is_folder).lower())
path = build_path(callback, self._args, self.params.raw_dict)
isfolder = callback.route.is_folder
elif callback:
else:
self.listitem.setProperty("isplayable", "true" if callback else "false")
self.listitem.setProperty("folder", "false")
path = callback
isfolder = False
else:
raise ValueError("Missing required callback")

if isfolder:
# Set Kodi icon image if not already set
Expand Down

0 comments on commit d22fa44

Please sign in to comment.