1
0
mirror of https://git.sr.ht/~adnano/go-gemini synced 2024-11-23 16:52:06 +01:00

Update switch statement

This commit is contained in:
adnano 2020-12-17 23:03:33 -05:00
parent 11797c1adc
commit 6a0c970814

@ -106,8 +106,8 @@ func (c *Client) do(req *Request, via []*Request) (*Response, error) {
// Store connection state
resp.TLS = conn.ConnectionState()
switch {
case resp.Status.Class() == StatusClassInput:
switch resp.Status.Class() {
case StatusClassInput:
if c.GetInput == nil {
break
}
@ -119,7 +119,7 @@ func (c *Client) do(req *Request, via []*Request) (*Response, error) {
return c.do(req, via)
}
case resp.Status.Class() == StatusClassRedirect:
case StatusClassRedirect:
if c.CheckRedirect == nil {
break
}