diff --git a/api/ovdashboard_api/async_helpers.py b/api/ovdashboard_api/async_helpers.py index ddc8919..a4a7ef9 100644 --- a/api/ovdashboard_api/async_helpers.py +++ b/api/ovdashboard_api/async_helpers.py @@ -36,14 +36,14 @@ def get_ttl_hash(seconds: int = 20) -> int: return round(time() / seconds) -def timed_alru_cache(**decorator_kwargs): +def timed_alru_cache(*decorator_args, **decorator_kwargs): """ Decorator which adds an (unused) param `ttl_hash` - and the `@alru_cache` annotation to a function. + and the `alru_cache` annotation to a function. """ def decorate(f): - @alru_cache(**decorator_kwargs) + @alru_cache(*decorator_args, **decorator_kwargs) @wraps(f) async def wrapper(ttl_hash: int, *args, **kwargs): del ttl_hash