File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
custom_components/remote_homeassistant Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -252,10 +252,13 @@ async def setup_components_and_platforms():
252252 """Set up platforms and initiate connection."""
253253 for domain in entry .options .get (CONF_LOAD_COMPONENTS , []):
254254 hass .async_create_task (async_setup_component (hass , domain , {}))
255- for component in PLATFORMS :
256- hass .async_create_task (
257- hass .config_entries .async_forward_entry_setup (entry , component )
258- )
255+
256+ await asyncio .gather (
257+ * [
258+ hass .config_entries .async_forward_entry_setup (entry , platform )
259+ for platform in PLATFORMS
260+ ]
261+ )
259262 await remote .async_connect ()
260263
261264 hass .async_create_task (setup_components_and_platforms ())
@@ -268,8 +271,8 @@ async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry):
268271 unload_ok = all (
269272 await asyncio .gather (
270273 * [
271- hass .config_entries .async_forward_entry_unload (entry , component )
272- for component in PLATFORMS
274+ hass .config_entries .async_forward_entry_unload (entry , platform )
275+ for platform in PLATFORMS
273276 ]
274277 )
275278 )
You can’t perform that action at this time.
0 commit comments