Merge pull request #1494 from croneter/py3-fix-typeerror

Fix videos not starting due to a TypeError
This commit is contained in:
croneter 2021-05-24 20:29:52 +02:00 committed by GitHub
commit 9872266c61
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -464,10 +464,11 @@ def prepare_listitem(item):
LOG.exception('Exception encountered: %s', exc)
def create_listitem(item, as_tuple=True, offscreen=True):
def create_listitem(item, as_tuple=True, offscreen=True,
listitem=xbmcgui.ListItem):
"""helper to create a kodi listitem from kodi compatible dict with mediainfo"""
try:
liz = xbmcgui.ListItem(
liz = listitem(
label=item.get("label", ""),
label2=item.get("label2", ""),
path=item['file'],