Skip to content

Commit

Permalink
Fix for #76 (use async_forward_entry_setups)
Browse files Browse the repository at this point in the history
  • Loading branch information
dummylabs committed Feb 2, 2023
1 parent e8c8d55 commit 23298fa
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion custom_components/watchman/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ async def async_setup_entry(hass: HomeAssistantType, entry: ConfigEntry):
hass.data[DOMAIN]["coordinator"] = coordinator
hass.data[DOMAIN_DATA] = entry.options # TODO: refactor

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))
await add_services(hass)
Expand All @@ -141,6 +141,12 @@ async def async_setup_entry(hass: HomeAssistantType, entry: ConfigEntry):
# parse_config will be scheduled once HA is fully loaded
_LOGGER.info("Watchman started [%s]", VERSION)


# resources = hass.data["lovelace"]["resources"]
# await resources.async_get_info()
# for itm in resources.async_items():
# _LOGGER.debug(itm)

return True


Expand Down

0 comments on commit 23298fa

Please sign in to comment.