mirror of
https://github.com/nalgeon/redka.git
synced 2025-10-26 09:30:24 +08:00
fix: command - always return non-nil command when parsing (fix #27)
To avoid panic when calling pcmd.Error in handlers.parse.
This commit is contained in:
@@ -37,6 +37,8 @@ func TestSInterParse(t *testing.T) {
|
||||
testx.AssertEqual(t, err, test.err)
|
||||
if err == nil {
|
||||
testx.AssertEqual(t, cmd.keys, test.want.keys)
|
||||
} else {
|
||||
testx.AssertEqual(t, cmd, test.want)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user