GetRespHead 获取返回头
(key string)
| 57 | |
| 58 | // GetRespHead 获取返回头 |
| 59 | func (h *Http) GetRespHead(key string) string { |
| 60 | if h.HttpResponse != nil { |
| 61 | return h.HttpResponse.Header.Get(key) |
| 62 | } |
| 63 | return "" |
| 64 | } |
| 65 | func (h *Http) readNull() ([]byte, error) { |
| 66 | _, err := io.Copy(io.Discard, h.HttpResponse.Body) |
| 67 | return nil, err |