From a73c89d42b3643ee62abd1988f825a94ee656d57 Mon Sep 17 00:00:00 2001 From: Alexandre Beslic Date: Wed, 13 May 2015 18:05:47 -0700 Subject: [PATCH] remove bool argument from getDirectory Signed-off-by: Alexandre Beslic --- pkg/store/etcd.go | 2 +- pkg/store/helpers.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/store/etcd.go b/pkg/store/etcd.go index 7b03bd8205..1f16052773 100644 --- a/pkg/store/etcd.go +++ b/pkg/store/etcd.go @@ -104,7 +104,7 @@ func (s *Etcd) Put(key string, value []byte) error { if etcdError, ok := err.(*etcd.EtcdError); ok { if etcdError.ErrorCode == 104 { // Not a directory // Remove the last element (the actual key) and set the prefix as a dir - err = s.createDirectory(getDirectory(key, false)) + err = s.createDirectory(getDirectory(key)) if _, err := s.client.Set(key, string(value), 0); err != nil { return err } diff --git a/pkg/store/helpers.go b/pkg/store/helpers.go index 99ba37eafd..a9386e31c1 100644 --- a/pkg/store/helpers.go +++ b/pkg/store/helpers.go @@ -24,7 +24,7 @@ func normalize(key string) string { // // /path/to/ // -func getDirectory(key string, omit bool) string { +func getDirectory(key string) string { parts := splitKey(key) parts = parts[:len(parts)-1] return "/" + join(parts)