Commit f19028e5 authored by Administrator's avatar Administrator

Update util.go

parent efa03ab9
...@@ -40,7 +40,7 @@ func toResponse(statusCode int, header interface{}, body []byte) *logResponse { ...@@ -40,7 +40,7 @@ func toResponse(statusCode int, header interface{}, body []byte) *logResponse {
var data interface{} var data interface{}
if body != nil { if body != nil {
if _err := json.Unmarshal(body, &data); _err != nil { if _err := json.Unmarshal(body, &data); _err != nil {
data = body data = string(body)
} }
} }
return &logResponse{ return &logResponse{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment