1
0
mirror of https://github.com/duke-git/lancet.git synced 2026-02-04 12:52:28 +08:00

release: update readme.file v1.0.8, ParseHttpResponse in netutil/request.go

This commit is contained in:
dudaodong
2021-12-20 11:43:39 +08:00
parent f1dbd943aa
commit 3045d56503
3 changed files with 5 additions and 3 deletions

View File

@@ -45,7 +45,7 @@ func HttpPatch(url string, params ...interface{}) (*http.Response, error) {
return request(http.MethodPatch, url, params...)
}
// ParseHttpResponse convert the http response to interface{} obj
// ParseHttpResponse decode http response to specified interface
func ParseHttpResponse(resp *http.Response, obj interface{}) error {
if resp == nil {
return errors.New("InvalidResp")