mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 04:37:06 +00:00
Start and stop template cache watcher to run_immediately (#113644)
This commit is contained in:
parent
68320b1278
commit
4d75940cd2
@ -209,8 +209,12 @@ def async_setup(hass: HomeAssistant) -> bool:
|
||||
cancel = async_track_time_interval(
|
||||
hass, _async_adjust_lru_sizes, timedelta(minutes=10)
|
||||
)
|
||||
hass.bus.async_listen_once(EVENT_HOMEASSISTANT_START, _async_adjust_lru_sizes)
|
||||
hass.bus.async_listen_once(EVENT_HOMEASSISTANT_STOP, callback(lambda _: cancel()))
|
||||
hass.bus.async_listen_once(
|
||||
EVENT_HOMEASSISTANT_START, _async_adjust_lru_sizes, run_immediately=True
|
||||
)
|
||||
hass.bus.async_listen_once(
|
||||
EVENT_HOMEASSISTANT_STOP, callback(lambda _: cancel()), run_immediately=True
|
||||
)
|
||||
return True
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user