mirror of
https://github.com/EchoVault/SugarDB.git
synced 2025-10-06 08:27:04 +08:00
Added command length tests for DECRBY command. Updated godoc comment for DecrBy embedded API method.
This commit is contained in:
@@ -155,9 +155,9 @@ func decrKeyFunc(cmd []string) (internal.KeyExtractionFuncResult, error) {
|
||||
}, nil
|
||||
}
|
||||
|
||||
func decrKeyByFunc(cmd []string) (internal.KeyExtractionFuncResult, error) {
|
||||
if len(cmd) < 3 {
|
||||
return internal.KeyExtractionFuncResult{}, errors.New("wrong number of arguments for DECRBY")
|
||||
func decrByKeyFunc(cmd []string) (internal.KeyExtractionFuncResult, error) {
|
||||
if len(cmd) != 3 {
|
||||
return internal.KeyExtractionFuncResult{}, errors.New(constants.WrongArgsResponse)
|
||||
}
|
||||
return internal.KeyExtractionFuncResult{
|
||||
WriteKeys: []string{cmd[1]},
|
||||
|
Reference in New Issue
Block a user