Remove extractKeys function

This commit is contained in:
ofekshenawa 2024-09-23 01:34:38 +03:00
parent 8de72d6d3c
commit be805cbe10
1 changed files with 0 additions and 24 deletions

View File

@ -122,30 +122,6 @@ func cmdString(cmd Cmder, val interface{}) string {
return util.BytesToString(b)
}
func extractKeys(cmd Cmder) []string {
firstKeyPos := cmdFirstKeyPos(cmd)
if firstKeyPos == -1 {
return nil
}
args := cmd.Args()
keys := []string{}
switch cmd.Name() {
case "mget":
for i := int(firstKeyPos); i < len(args); i++ {
keys = append(keys, cmd.stringArg(i))
}
default:
if int(firstKeyPos) < len(args) {
keys = append(keys, cmd.stringArg(firstKeyPos))
}
}
return keys
}
//------------------------------------------------------------------------------
type baseCmd struct {