异常不退出

This commit is contained in:
suguo.yao 2022-08-13 22:16:47 +08:00
parent 1310a49824
commit d473317c7c
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ func Post(endpoint string, postBody string, authorization string) string {
client := &http.Client{} client := &http.Client{}
resp, err := client.Do(req) resp, err := client.Do(req)
if err != nil { if err != nil {
panic(err) return err.Error()
} }
defer resp.Body.Close() defer resp.Body.Close()
// body, _ := ioutil.ReadAll(resp.Body) // body, _ := ioutil.ReadAll(resp.Body)