Skip to content

Commit

Permalink
Update __init__.py
Browse files Browse the repository at this point in the history
Change `async_setup_entry` to use `await hass.config_entries.async_forward_entry_setups(config_entry, PLATFORMS)`
  • Loading branch information
danielbrunt57 authored Aug 2, 2024
1 parent 8e8c520 commit 23ff024
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions custom_components/adaptive_lighting/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,7 @@ async def async_setup_entry(hass: HomeAssistant, config_entry: ConfigEntry):

undo_listener = config_entry.add_update_listener(async_update_options)
data[config_entry.entry_id] = {UNDO_UPDATE_LISTENER: undo_listener}
for platform in PLATFORMS:
hass.async_create_task(
hass.config_entries.async_forward_entry_setup(config_entry, platform),
)
await hass.config_entries.async_forward_entry_setups(config_entry, PLATFORMS)

return True

Expand Down

0 comments on commit 23ff024

Please sign in to comment.