mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
client: fix from go vet, go lint
This commit is contained in:
parent
6557ef7cd8
commit
e2138179e3
@ -645,7 +645,7 @@ func assertRequest(got http.Request, wantMethod string, wantURL *url.URL, wantHe
|
|||||||
} else {
|
} else {
|
||||||
if wantBody == nil {
|
if wantBody == nil {
|
||||||
return fmt.Errorf("want.Body=%v got.Body=%s", wantBody, got.Body)
|
return fmt.Errorf("want.Body=%v got.Body=%s", wantBody, got.Body)
|
||||||
} else {
|
}
|
||||||
gotBytes, err := ioutil.ReadAll(got.Body)
|
gotBytes, err := ioutil.ReadAll(got.Body)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
@ -655,7 +655,6 @@ func assertRequest(got http.Request, wantMethod string, wantURL *url.URL, wantHe
|
|||||||
return fmt.Errorf("want.Body=%s got.Body=%s", wantBody, gotBytes)
|
return fmt.Errorf("want.Body=%s got.Body=%s", wantBody, gotBytes)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user