mirror of
https://github.com/EchoVault/SugarDB.git
synced 2025-10-13 19:55:14 +08:00
Begining to implement Append command
This commit is contained in:
@@ -17,6 +17,7 @@ package str
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
|
||||
"github.com/echovault/echovault/internal"
|
||||
"github.com/echovault/echovault/internal/constants"
|
||||
)
|
||||
@@ -166,6 +167,10 @@ func handleSubStr(params internal.HandlerFuncParams) ([]byte, error) {
|
||||
return []byte(fmt.Sprintf("$%d\r\n%s\r\n", len(str), str)), nil
|
||||
}
|
||||
|
||||
func handleAppend(params internal.HandlerFuncParams) ([]byte, error) {
|
||||
return []byte("Hello World"), nil
|
||||
}
|
||||
|
||||
func Commands() []internal.Command {
|
||||
return []internal.Command{
|
||||
{
|
||||
|
Reference in New Issue
Block a user