From 22eeabc262a322239f87f54010747fbb60f37d42 Mon Sep 17 00:00:00 2001 From: aunefyren Date: Tue, 30 Jan 2024 15:39:52 +0100 Subject: [PATCH] Update media_player.py --- custom_components/bluesound_alt/media_player.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/custom_components/bluesound_alt/media_player.py b/custom_components/bluesound_alt/media_player.py index 86479d2..3b34b12 100644 --- a/custom_components/bluesound_alt/media_player.py +++ b/custom_components/bluesound_alt/media_player.py @@ -879,9 +879,11 @@ async def rebuild_bluesound_group(self): f"/SyncStatus" ) - slaves = sync_status["SyncStatus"] - _LOGGER.debug("Slaves: %s", slaves) - + slaves = [] + for key in sync_status["SyncStatus"].iter(): + if key.name == "slave": + _LOGGER.debug("Slave: %s", key.id) + slaves.append(key.id + ":" + key.port) for slave in slaves: new_device_group.append(slave.id + ":" + slave.port)