Skip to content

Commit

Permalink
Replace current async_setup_platforms function with async_forward_ent…
Browse files Browse the repository at this point in the history
…ry_setups, which will prevent the integration failing to start in Home Assistant 2023.3+
  • Loading branch information
StephanJoubert committed Feb 11, 2023
1 parent 3788e7a commit 0cd2e8d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/solarman/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up Solarman Collector from a config entry."""
_LOGGER.debug(f'__init__.py:async_setup_entry({entry.as_dict()})')
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
entry.async_on_unload(entry.add_update_listener(update_listener))
return True

Expand Down

1 comment on commit 0cd2e8d

@MinzeB
Copy link

@MinzeB MinzeB commented on 0cd2e8d Jul 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes nice, this solves my problem! Thanx!

Please sign in to comment.