diff --git a/limitador/src/storage/redis/redis_async.rs b/limitador/src/storage/redis/redis_async.rs index 31bf946e..85563792 100644 --- a/limitador/src/storage/redis/redis_async.rs +++ b/limitador/src/storage/redis/redis_async.rs @@ -229,6 +229,8 @@ impl AsyncRedisStorage { .await?; } + con.del::<_, ()>(key_for_counters_of_limit(limit)).await?; + Ok(()) } } diff --git a/limitador/src/storage/redis/redis_sync.rs b/limitador/src/storage/redis/redis_sync.rs index 4c0619ee..08e5082b 100644 --- a/limitador/src/storage/redis/redis_sync.rs +++ b/limitador/src/storage/redis/redis_sync.rs @@ -156,6 +156,7 @@ impl CounterStorage for RedisStorage { for counter_key in counter_keys { con.del::<_, ()>(counter_key)?; } + con.del::<_, ()>(key_for_counters_of_limit(limit))?; } Ok(())