response: Revert to using fields instead of methods
This commit is contained in:
parent
867074d81b
commit
1bc5c68c3f
2
doc.go
2
doc.go
@ -9,7 +9,7 @@ Client is a Gemini client.
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
// handle error
|
// handle error
|
||||||
}
|
}
|
||||||
defer resp.Close()
|
defer resp.Body.Close()
|
||||||
// ...
|
// ...
|
||||||
|
|
||||||
Server is a Gemini server.
|
Server is a Gemini server.
|
||||||
|
|||||||
@ -103,9 +103,9 @@ func do(req *gemini.Request, via []*gemini.Request) (*gemini.Response, error) {
|
|||||||
return resp, err
|
return resp, err
|
||||||
}
|
}
|
||||||
|
|
||||||
switch resp.Status().Class() {
|
switch resp.Status.Class() {
|
||||||
case gemini.StatusInput:
|
case gemini.StatusInput:
|
||||||
input, ok := getInput(resp.Meta(), resp.Status() == gemini.StatusSensitiveInput)
|
input, ok := getInput(resp.Meta, resp.Status == gemini.StatusSensitiveInput)
|
||||||
if !ok {
|
if !ok {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||