Procházet zdrojové kódy

store: fixes shadowed variables with go tool vet.

Fixes for https://github.com/coreos/etcd/issues/3954.
Gyu-Ho Lee před 10 roky
rodič
revize
a45b902d12
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      store/event_history.go

+ 1 - 1
store/event_history.go

@@ -82,7 +82,7 @@ func (eh *EventHistory) scan(key string, recursive bool, index uint64) (*Event,
 
 
 		if recursive {
 		if recursive {
 			// add tailing slash
 			// add tailing slash
-			key := path.Clean(key)
+			key = path.Clean(key)
 			if key[len(key)-1] != '/' {
 			if key[len(key)-1] != '/' {
 				key = key + "/"
 				key = key + "/"
 			}
 			}