diff --git a/src/RedisRateLimiting/SlidingWindow/RedisSlidingWindowManager.cs b/src/RedisRateLimiting/SlidingWindow/RedisSlidingWindowManager.cs index c1a9f5b..cfc65d7 100644 --- a/src/RedisRateLimiting/SlidingWindow/RedisSlidingWindowManager.cs +++ b/src/RedisRateLimiting/SlidingWindow/RedisSlidingWindowManager.cs @@ -38,6 +38,8 @@ internal class RedisSlidingWindowManager redis.call(""hincrby"", @stats_key, 'total_failed', 1) end + redis.call(""pexpireat"", @stats_key, expireAtMilliseconds) + return { allowed, count }"); private static readonly LuaScript StatisticsScript = LuaScript.Prepare(