Run get_plugin at every iteration of the mpd backend in case the plugin lost the connection and has been reloaded
This commit is contained in:
parent
1a01b336b7
commit
607ec2812c
1 changed files with 1 additions and 1 deletions
|
@ -24,12 +24,12 @@ class MusicMpdBackend(Backend):
|
|||
def run(self):
|
||||
super().run()
|
||||
|
||||
plugin = get_plugin('music.mpd')
|
||||
last_state = None
|
||||
last_track = None
|
||||
last_playlist = None
|
||||
|
||||
while not self.should_stop():
|
||||
plugin = get_plugin('music.mpd')
|
||||
status = plugin.status().output
|
||||
track = plugin.currentsong().output
|
||||
state = status['state'].lower()
|
||||
|
|
Loading…
Reference in a new issue