Skip to content

Commit

Permalink
Fix setup Fast.com (#105580)
Browse files Browse the repository at this point in the history
* Fix setup fastdotcom

* Add if
  • Loading branch information
gjohansson-ST authored and frenck committed Dec 13, 2023
1 parent fbb315b commit 8b3ba45
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions homeassistant/components/fastdotcom/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,16 @@
)


async def async_setup_platform(hass: HomeAssistant, config: ConfigType) -> bool:
async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
"""Set up the Fast.com component. (deprecated)."""
hass.async_create_task(
hass.config_entries.flow.async_init(
DOMAIN,
context={"source": SOURCE_IMPORT},
data=config[DOMAIN],
if DOMAIN in config:
hass.async_create_task(
hass.config_entries.flow.async_init(
DOMAIN,
context={"source": SOURCE_IMPORT},
data=config[DOMAIN],
)
)
)
return True


Expand Down

0 comments on commit 8b3ba45

Please sign in to comment.