feat: add schema v1 ddl for children and admin_users (#13)

This commit was merged in pull request #13.
This commit is contained in:
2026-09-13 21:39:18 -04:00
parent eaf2e45e9a
commit 3dae2eadd7
3 changed files with 347 additions and 0 deletions
+2
View File
@@ -11,6 +11,7 @@ from homeassistant.core import HomeAssistant
from .const import DOMAIN, LOGGER
from .db import NestQuestDatabase
from .schema import SCHEMA_V1_STATEMENTS, async_apply_ddl
from .store import async_get_db_path
_LOGGER = LOGGER
@@ -51,6 +52,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
database = await NestQuestDatabase(hass).open(await async_get_db_path(hass))
try:
await async_apply_ddl(database, SCHEMA_V1_STATEMENTS)
remove_update_listener = entry.add_update_listener(_async_update_listener)
except BaseException:
await database.close()