From 2e7e7fef609be2019d48c492302a49a58f1fc29a Mon Sep 17 00:00:00 2001 From: croneter Date: Wed, 14 Feb 2018 21:02:04 +0100 Subject: [PATCH] Fallback if we didn't get any info on playing element --- resources/lib/playlist_func.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/resources/lib/playlist_func.py b/resources/lib/playlist_func.py index de480620..ba0457bf 100644 --- a/resources/lib/playlist_func.py +++ b/resources/lib/playlist_func.py @@ -367,6 +367,11 @@ def init_Plex_playlist(playlist, plex_id=None, kodi_item=None): """ LOG.debug('Initializing the playlist on the Plex side: %s', playlist) playlist.clear(kodi=False) + if plex_id is None and kodi_item.get('id') is None: + LOG.debug('We dont know plex nor Kodi id, starting lookup') + for playerid in js.get_player_ids(): + json_item = js.get_item(playerid) + kodi_item.update(json_item) try: if plex_id: item = playlist_item_from_plex(plex_id)