Add list to async_delay_save typing (#66795)
This commit is contained in:
parent
046c0ae61b
commit
0ac9376ee4
1 changed files with 5 additions and 1 deletions
|
@ -194,7 +194,11 @@ class Store:
|
|||
await self._async_handle_write_data()
|
||||
|
||||
@callback
|
||||
def async_delay_save(self, data_func: Callable[[], dict], delay: float = 0) -> None:
|
||||
def async_delay_save(
|
||||
self,
|
||||
data_func: Callable[[], dict | list],
|
||||
delay: float = 0,
|
||||
) -> None:
|
||||
"""Save data with an optional delay."""
|
||||
# pylint: disable-next=import-outside-toplevel
|
||||
from .event import async_call_later
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue