Compare commits

..

1 Commits

Author SHA1 Message Date
den-dmitriev
776c010793 Merge ca0f132434 into 40ae6041ae 2025-02-16 09:31:15 +00:00
5 changed files with 10 additions and 7 deletions

View File

@@ -1,5 +1,5 @@
[bumpversion] [bumpversion]
current_version = 1.1.8b14 current_version = 1.1.8b12
parse = (?P<major>\d+)(\.(?P<minor>\d+))(\.(?P<patch>\d+))(?P<release>[bf]*)(?P<build>\d*) parse = (?P<major>\d+)(\.(?P<minor>\d+))(\.(?P<patch>\d+))(?P<release>[bf]*)(?P<build>\d*)
commit = True commit = True
tag = True tag = True

View File

@@ -254,8 +254,10 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry):
_hubs[entry.entry_id] = hub _hubs[entry.entry_id] = hub
_subs[entry.entry_id] = entry.add_update_listener(updater) _subs[entry.entry_id] = entry.add_update_listener(updater)
await hub.start() await hub.start()
# for platform in PLATFORMS: for platform in PLATFORMS:
await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS) hass.async_create_task(
hass.config_entries.async_forward_entry_setup(entry, platform)
)
await hub.updater.async_refresh() await hub.updater.async_refresh()
return True return True
@@ -312,7 +314,8 @@ async def async_migrate_entry(hass, config_entry: ConfigEntry):
await hub.stop() await hub.stop()
new.update(cfg) new.update(cfg)
_LOGGER.debug(f"new config: %s", new) _LOGGER.debug(f"new config: %s", new)
hass.config_entries.async_update_entry(config_entry, data=new, version=ConfigFlow.VERSION) config_entry.data = new
config_entry.version = ConfigFlow.VERSION
_LOGGER.info("Migration to version %s successful", config_entry.version) _LOGGER.info("Migration to version %s successful", config_entry.version)

View File

@@ -130,7 +130,7 @@ class OptionsFlowHandler(config_entries.OptionsFlow):
cfg = dict(self.config_entry.data) cfg = dict(self.config_entry.data)
cfg.update(user_input) cfg.update(user_input)
cfg["new_naming"] = new_naming cfg["new_naming"] = new_naming
self.hass.config_entries.async_update_entry(entry=self.config_entry, data=cfg) self.config_entry.data = cfg
await get_hub(self.hass, cfg) await get_hub(self.hass, cfg)
if reload: if reload:

View File

@@ -689,7 +689,7 @@ class MegaD:
cfg.pop(x, None) cfg.pop(x, None)
cfg.update(new) cfg.update(new)
self.lg.debug(f"new config: %s", cfg) self.lg.debug(f"new config: %s", cfg)
self.hass.config_entries.async_update_entry(self.config, data=cfg) self.config.data = cfg
if reload_entry: if reload_entry:
await self.hass.config_entries.async_reload(self.config.entry_id) await self.hass.config_entries.async_reload(self.config.entry_id)
return cfg return cfg

View File

@@ -16,5 +16,5 @@
"@den-dmitriev" "@den-dmitriev"
], ],
"issue_tracker": "https://github.com/andvikt/mega_hacs/issues", "issue_tracker": "https://github.com/andvikt/mega_hacs/issues",
"version": "v1.1.8b14" "version": "v1.1.8b13"
} }