瀏覽代碼

store: fixes shadowed variables with go tool vet.

Fixes for https://github.com/coreos/etcd/issues/3954.
Gyu-Ho Lee 10 年之前
父節點
當前提交
a45b902d12
共有 1 個文件被更改,包括 1 次插入1 次删除
  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 {
 			// add tailing slash
-			key := path.Clean(key)
+			key = path.Clean(key)
 			if key[len(key)-1] != '/' {
 				key = key + "/"
 			}