add utils.log
This commit is contained in:
parent
73f473fc51
commit
0e13808b71
4
utils.go
4
utils.go
@ -13,6 +13,10 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
func log(msg interface{}) {
|
||||||
|
fmt.Println(msg)
|
||||||
|
}
|
||||||
|
|
||||||
func Error(r *http.Response) error {
|
func Error(r *http.Response) error {
|
||||||
return errors.New(fmt.Sprintf("%s - %s %s", r.Status, r.Request.Method, r.Request.URL.String()))
|
return errors.New(fmt.Sprintf("%s - %s %s", r.Status, r.Request.Method, r.Request.URL.String()))
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user