Skip to content

Commit

Permalink
await async init and setup
Browse files Browse the repository at this point in the history
  • Loading branch information
myTselection committed Jul 2, 2024
1 parent 63ced04 commit 6f973f5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions custom_components/myenergy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ async def async_setup(hass: HomeAssistant, config: dict):
pass

hass.async_create_task(
hass.config_entries.flow.async_init(
await hass.config_entries.flow.async_init(
DOMAIN, context={"source": config_entries.SOURCE_IMPORT}, data={}
)
)
Expand All @@ -73,7 +73,7 @@ async def async_unload_entry(hass: HomeAssistant, config_entry: ConfigEntry):
async def async_setup_entry(hass: HomeAssistant, config_entry: ConfigEntry) -> bool:
"""Set up component as config entry."""
hass.async_create_task(
hass.config_entries.async_forward_entry_setup(config_entry, Platform.SENSOR)
await hass.config_entries.async_forward_entry_setup(config_entry, Platform.SENSOR)
)
config_entry.async_on_unload(config_entry.add_update_listener(update_listener))
# _LOGGER.info(f"{DOMAIN} register_services")
Expand Down
2 changes: 1 addition & 1 deletion custom_components/myenergy/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
"iot_class": "cloud_polling",
"issue_tracker": "https://github.com/myTselection/MyEnergy/issues",
"requirements": ["bs4","requests"],
"version": "2.4.1"
"version": "2.4.2"
}

0 comments on commit 6f973f5

Please sign in to comment.