clean format with gofmt -w
parent
823691feaa
commit
9da955ca75
|
@ -280,7 +280,6 @@ func (s *Store) internalGet(key string) *Response {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
// Get all the items under key
|
||||
// If key is a file return the file
|
||||
// If key is a directory reuturn an array of files
|
||||
|
@ -352,7 +351,6 @@ func (s *Store) Delete(key string, index uint64) ([]byte, error) {
|
|||
|
||||
s.Tree.delete(key)
|
||||
|
||||
|
||||
} else {
|
||||
resp.Expiration = &node.ExpireTime
|
||||
// Kill the expire go routine
|
||||
|
|
|
@ -2,8 +2,8 @@ package store
|
|||
|
||||
import (
|
||||
"path"
|
||||
"strings"
|
||||
"sort"
|
||||
"strings"
|
||||
)
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
package store
|
||||
|
||||
import (
|
||||
"testing"
|
||||
"fmt"
|
||||
"math/rand"
|
||||
"strconv"
|
||||
"testing"
|
||||
"time"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
func TestStoreGet(t *testing.T) {
|
||||
|
@ -60,7 +60,6 @@ func TestStoreGet(t *testing.T) {
|
|||
t.Fatalf("Expect cannot delet /hello, but deleted! ")
|
||||
}
|
||||
|
||||
|
||||
// test list
|
||||
ts.set("/hello/fooo", CreateTestNode("barbarbar"))
|
||||
ts.set("/hello/foooo/foo", CreateTestNode("barbarbar"))
|
||||
|
|
|
@ -5,6 +5,7 @@ import (
|
|||
"strconv"
|
||||
"strings"
|
||||
)
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
//
|
||||
// Typedefs
|
||||
|
@ -85,7 +86,6 @@ func checkResponse(prefix string, index uint64, resMap *map[string]Response) boo
|
|||
return false
|
||||
}
|
||||
|
||||
|
||||
// Notify the watcher a action happened
|
||||
func (w *WatcherHub) notify(resp Response) error {
|
||||
resp.Key = path.Clean(resp.Key)
|
||||
|
|
Loading…
Reference in New Issue