|
@@ -5,13 +5,12 @@ import (
|
|
|
"encoding/json"
|
|
|
"encoding/xml"
|
|
|
"errors"
|
|
|
- "fmt"
|
|
|
|
|
|
"git.chuangxin1.com/cx/myth"
|
|
|
)
|
|
|
|
|
|
func checkJSONError(msg myth.HTTPMessage) (jq *myth.JSONQuery, err error) {
|
|
|
- fmt.Println(msg.StatusCode, string(msg.Body))
|
|
|
+ //fmt.Println(msg.StatusCode, string(msg.Body))
|
|
|
if msg.StatusCode == 200 {
|
|
|
jq, err = msg.JSONQuery()
|
|
|
if err != nil {
|
|
@@ -60,7 +59,7 @@ func getBody(uri string) (msg myth.HTTPMessage, err error) {
|
|
|
if err != nil {
|
|
|
return
|
|
|
}
|
|
|
- fmt.Println(msg.StatusCode, string(msg.Body))
|
|
|
+ //fmt.Println(msg.StatusCode, string(msg.Body))
|
|
|
if msg.StatusCode == 200 {
|
|
|
jq := &myth.JSONQuery{}
|
|
|
jq, err = msg.JSONQuery()
|