Remove obsolete playlistitem attribute

This commit is contained in:
croneter 2018-02-03 15:04:05 +01:00
parent 48dc22ee35
commit 35536fdc2f
2 changed files with 0 additions and 11 deletions

View file

@ -247,8 +247,6 @@ class KodiMonitor(Monitor):
kodi_item=data['item']) kodi_item=data['item'])
except PL.PlaylistError: except PL.PlaylistError:
pass pass
# Make sure that we won't re-add this item
# playqueue.old_kodi_pl = kodi_playqueue
@LOCKER.lockthis @LOCKER.lockthis
def _playlist_onremove(self, data): def _playlist_onremove(self, data):
@ -264,13 +262,7 @@ class KodiMonitor(Monitor):
if playqueue.is_kodi_onremove() is False: if playqueue.is_kodi_onremove() is False:
LOG.debug('PKC removed this item already from playqueue - ignoring') LOG.debug('PKC removed this item already from playqueue - ignoring')
return return
# Check whether we even need to update our known playqueue
kodi_playqueue = js.playlist_get_items(data['playlistid'])
if playqueue.old_kodi_pl == kodi_playqueue:
# We already know the latest playqueue - nothing to do
return
PL.delete_playlist_item_from_PMS(playqueue, data['position']) PL.delete_playlist_item_from_PMS(playqueue, data['position'])
playqueue.old_kodi_pl = kodi_playqueue
@LOCKER.lockthis @LOCKER.lockthis
def _playlist_onclear(self, data): def _playlist_onclear(self, data):

View file

@ -38,7 +38,6 @@ class PlaylistObjectBaseclase(object):
self.type = None self.type = None
self.kodi_pl = None self.kodi_pl = None
self.items = [] self.items = []
self.old_kodi_pl = []
self.id = None self.id = None
self.version = None self.version = None
self.selectedItemID = None self.selectedItemID = None
@ -137,7 +136,6 @@ class PlaylistObjectBaseclase(object):
self.kodi_onclear() self.kodi_onclear()
self.kodi_pl.clear() # Clear Kodi playlist object self.kodi_pl.clear() # Clear Kodi playlist object
self.items = [] self.items = []
self.old_kodi_pl = []
self.id = None self.id = None
self.version = None self.version = None
self.selectedItemID = None self.selectedItemID = None
@ -163,7 +161,6 @@ class Playqueue_Object(PlaylistObjectBaseclase):
type = None [str] Kodi type: 'audio', 'video', 'picture' type = None [str] Kodi type: 'audio', 'video', 'picture'
kodi_pl = None Kodi xbmc.PlayList object kodi_pl = None Kodi xbmc.PlayList object
items = [] [list] of Playlist_Items items = [] [list] of Playlist_Items
old_kodi_pl = [] [list] store old Kodi JSON result with all pl items
id = None [str] Plex playQueueID, unique Plex identifier id = None [str] Plex playQueueID, unique Plex identifier
version = None [int] Plex version of the playQueue version = None [int] Plex version of the playQueue
selectedItemID = None selectedItemID = None