mirror of
https://github.com/home-assistant/core.git
synced 2025-07-14 16:57:10 +00:00
Explicitly pass in the config_entry in thethingsnetwork coordinator (#137905)
explicitly pass in the config_entry in coordinator
This commit is contained in:
parent
794143c32f
commit
4031f85acc
@ -19,11 +19,14 @@ _LOGGER = logging.getLogger(__name__)
|
|||||||
class TTNCoordinator(DataUpdateCoordinator[TTNClient.DATA_TYPE]):
|
class TTNCoordinator(DataUpdateCoordinator[TTNClient.DATA_TYPE]):
|
||||||
"""TTN coordinator."""
|
"""TTN coordinator."""
|
||||||
|
|
||||||
|
config_entry: ConfigEntry
|
||||||
|
|
||||||
def __init__(self, hass: HomeAssistant, entry: ConfigEntry) -> None:
|
def __init__(self, hass: HomeAssistant, entry: ConfigEntry) -> None:
|
||||||
"""Initialize my coordinator."""
|
"""Initialize my coordinator."""
|
||||||
super().__init__(
|
super().__init__(
|
||||||
hass,
|
hass,
|
||||||
_LOGGER,
|
_LOGGER,
|
||||||
|
config_entry=entry,
|
||||||
# Name of the data. For logging purposes.
|
# Name of the data. For logging purposes.
|
||||||
name=f"TheThingsNetwork_{entry.data[CONF_APP_ID]}",
|
name=f"TheThingsNetwork_{entry.data[CONF_APP_ID]}",
|
||||||
# Polling interval. Will only be polled if there are subscribers.
|
# Polling interval. Will only be polled if there are subscribers.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user