From 346bd9602da14b50867ffd4b2a84a0051e6445e1 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Wed, 3 Feb 2021 17:44:40 +0100 Subject: [PATCH] The whole get_plugin/.status() block should be under try/except --- platypush/plugins/media/ctrl.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/platypush/plugins/media/ctrl.py b/platypush/plugins/media/ctrl.py index 117b0691a..3a3eb4a05 100644 --- a/platypush/plugins/media/ctrl.py +++ b/platypush/plugins/media/ctrl.py @@ -67,10 +67,10 @@ class MediaCtrlPlugin(Plugin): if configured_media_plugins: try: plugin = get_plugin(configured_media_plugins[0]) + status = plugin.status().output except: - pass + continue - status = plugin.status().output if status.get('state') == PlayerState.PLAY.value or status.get('state') == PlayerState.PAUSE.value: return plugin