diff --git a/cache/redis/redis.go b/cache/redis/redis.go index a1ea7b49..7a14b012 100644 --- a/cache/redis/redis.go +++ b/cache/redis/redis.go @@ -151,6 +151,7 @@ func (rc *Cache) ClearAll() error { return err } +// Scan scan all keys matching the pattern. a better choice than `keys` func (rc *Cache) Scan(pattern string) (keys []string, err error) { c := rc.p.Get() defer c.Close()