1
0
mirror of https://github.com/redis/go-redis.git synced 2025-07-31 05:04:23 +03:00

Fix Del command case.

This commit is contained in:
Vladimir Mihailenco
2016-07-08 09:24:02 +00:00
parent 4d018d831e
commit 261cf7ae70
3 changed files with 4 additions and 2 deletions

View File

@ -169,6 +169,7 @@ func (c *Ring) cmdInfo(name string) *CommandInfo {
func (c *Ring) cmdFirstKey(cmd Cmder) string {
cmdInfo := c.cmdInfo(cmd.arg(0))
if cmdInfo == nil {
internal.Logf("info for cmd=%s not found", cmd.arg(0))
return ""
}
return cmd.arg(int(cmdInfo.FirstKeyPos))