mirror of https://github.com/go-redis/redis.git
Cleanup
This commit is contained in:
parent
eb64034d44
commit
dab9d3f802
2
Makefile
2
Makefile
|
@ -4,8 +4,6 @@ all: testdeps
|
||||||
go test ./... -run=NONE -bench=. -benchmem
|
go test ./... -run=NONE -bench=. -benchmem
|
||||||
env GOOS=linux GOARCH=386 go test ./...
|
env GOOS=linux GOARCH=386 go test ./...
|
||||||
go vet
|
go vet
|
||||||
go get github.com/gordonklaus/ineffassign
|
|
||||||
ineffassign .
|
|
||||||
golangci-lint run
|
golangci-lint run
|
||||||
|
|
||||||
testdeps: testdata/redis/src/redis-server
|
testdeps: testdata/redis/src/redis-server
|
||||||
|
|
11
command.go
11
command.go
|
@ -2005,12 +2005,15 @@ func (c *cmdsInfoCache) Get() (map[string]*CommandInfo, error) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
for key := range cmds {
|
|
||||||
lowerKey := internal.ToLower(key)
|
// Extensions have cmd names in upper case. Convert them to lower case.
|
||||||
if key != lowerKey {
|
for k, v := range cmds {
|
||||||
cmds[lowerKey] = cmds[key]
|
lower := internal.ToLower(k)
|
||||||
|
if lower != k {
|
||||||
|
cmds[lower] = v
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
c.cmds = cmds
|
c.cmds = cmds
|
||||||
return nil
|
return nil
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue