mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Avoid call to hass.helpers.store
in CategoryRegistry (#114485)
This commit is contained in:
parent
ef5f6829e7
commit
502231b7d2
@ -11,6 +11,7 @@ from homeassistant.core import HomeAssistant, callback
|
||||
from homeassistant.util.ulid import ulid_now
|
||||
|
||||
from .registry import BaseRegistry
|
||||
from .storage import Store
|
||||
from .typing import UNDEFINED, EventType, UndefinedType
|
||||
|
||||
DATA_REGISTRY = "category_registry"
|
||||
@ -46,7 +47,8 @@ class CategoryRegistry(BaseRegistry):
|
||||
"""Initialize the category registry."""
|
||||
self.hass = hass
|
||||
self.categories: dict[str, dict[str, CategoryEntry]] = {}
|
||||
self._store = hass.helpers.storage.Store(
|
||||
self._store: Store[dict[str, dict[str, list[dict[str, str]]]]] = Store(
|
||||
hass,
|
||||
STORAGE_VERSION_MAJOR,
|
||||
STORAGE_KEY,
|
||||
atomic_writes=True,
|
||||
|
Loading…
x
Reference in New Issue
Block a user