mirror of
https://github.com/redis/go-redis.git
synced 2025-06-12 14:21:52 +03:00
Support multiple keys for the PFCOUNT command
This commit is contained in:
@ -1340,8 +1340,13 @@ func (c *commandable) PFAdd(key string, fields ...string) *IntCmd {
|
||||
return cmd
|
||||
}
|
||||
|
||||
func (c *commandable) PFCount(key string) *IntCmd {
|
||||
cmd := NewIntCmd("PFCOUNT", key)
|
||||
func (c *commandable) PFCount(keys ...string) *IntCmd {
|
||||
args := make([]interface{}, 1+len(keys))
|
||||
args[0] = "PFCOUNT"
|
||||
for i, key := range keys {
|
||||
args[1+i] = key
|
||||
}
|
||||
cmd := NewIntCmd(args...)
|
||||
c.Process(cmd)
|
||||
return cmd
|
||||
}
|
||||
|
Reference in New Issue
Block a user