Skip to content

Commit

Permalink
Update helpers.py
Browse files Browse the repository at this point in the history
Iterate on a copy of the existing_serials rather than extend the list being iterated
  • Loading branch information
dpwood authored Oct 4, 2024
1 parent bdbec38 commit 3672768
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/alexa_media/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ def _existing_serials(hass, login_obj) -> list:
.get("devices", {})
.get("media_player", {})
)
for serial in existing_serials:
for serial in existing_serials[:]:
device = device_data.get(serial, {})
if "appDeviceList" in device and device["appDeviceList"]:
apps = [
Expand Down

0 comments on commit 3672768

Please sign in to comment.