Browse Source

etcdhttp: parse boolpointer

Xiang Li 11 years ago
parent
commit
c84a25e433
1 changed files with 2 additions and 2 deletions
  1. 2 2
      etcdserver2/etcdhttp/http.go

+ 2 - 2
etcdserver2/etcdhttp/http.go

@@ -97,9 +97,9 @@ func parseRequest(r *http.Request) etcdserverpb.Request {
 
 
 	// PrevExists is nullable, so we leave it null if prevExist wasn't
 	// PrevExists is nullable, so we leave it null if prevExist wasn't
 	// specified.
 	// specified.
-	_, ok := q["wait"]
+	_, ok := q["prevExists"]
 	if ok {
 	if ok {
-		bv := parseBool(q.Get("wait"))
+		bv := parseBool(q.Get("prevExists"))
 		rr.PrevExists = &bv
 		rr.PrevExists = &bv
 	}
 	}