Code cleanup
This commit is contained in:
parent
ecc8df014c
commit
5f26692e0f
2 changed files with 6 additions and 5 deletions
|
@ -18,11 +18,12 @@ LOG = getLogger("PLEX." + __name__)
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
|
|
||||||
class Playback_Starter(Thread):
|
class PlaybackStarter(Thread):
|
||||||
"""
|
"""
|
||||||
Processes new plays
|
Processes new plays
|
||||||
"""
|
"""
|
||||||
def triage(self, item):
|
@staticmethod
|
||||||
|
def _triage(item):
|
||||||
try:
|
try:
|
||||||
_, params = item.split('?', 1)
|
_, params = item.split('?', 1)
|
||||||
except ValueError:
|
except ValueError:
|
||||||
|
@ -58,6 +59,6 @@ class Playback_Starter(Thread):
|
||||||
# Need to shutdown - initiated by command_pipeline
|
# Need to shutdown - initiated by command_pipeline
|
||||||
break
|
break
|
||||||
else:
|
else:
|
||||||
self.triage(item)
|
self._triage(item)
|
||||||
queue.task_done()
|
queue.task_done()
|
||||||
LOG.info("----===## Playback_Starter stopped ##===----")
|
LOG.info("----===## Playback_Starter stopped ##===----")
|
||||||
|
|
|
@ -38,7 +38,7 @@ from websocket_client import PMS_Websocket, Alexa_Websocket
|
||||||
from PlexFunctions import check_connection
|
from PlexFunctions import check_connection
|
||||||
from PlexCompanion import PlexCompanion
|
from PlexCompanion import PlexCompanion
|
||||||
from command_pipeline import Monitor_Window
|
from command_pipeline import Monitor_Window
|
||||||
from playback_starter import Playback_Starter
|
from playback_starter import PlaybackStarter
|
||||||
from playqueue import PlayqueueMonitor
|
from playqueue import PlayqueueMonitor
|
||||||
from artwork import Image_Cache_Thread
|
from artwork import Image_Cache_Thread
|
||||||
import variables as v
|
import variables as v
|
||||||
|
@ -111,7 +111,7 @@ class Service():
|
||||||
self.library = LibrarySync()
|
self.library = LibrarySync()
|
||||||
self.plexCompanion = PlexCompanion()
|
self.plexCompanion = PlexCompanion()
|
||||||
self.specialMonitor = SpecialMonitor()
|
self.specialMonitor = SpecialMonitor()
|
||||||
self.playback_starter = Playback_Starter()
|
self.playback_starter = PlaybackStarter()
|
||||||
self.playqueue = PlayqueueMonitor()
|
self.playqueue = PlayqueueMonitor()
|
||||||
if settings('enableTextureCache') == "true":
|
if settings('enableTextureCache') == "true":
|
||||||
self.image_cache_thread = Image_Cache_Thread()
|
self.image_cache_thread = Image_Cache_Thread()
|
||||||
|
|
Loading…
Reference in a new issue