|
@@ -2,7 +2,7 @@ package wechat
|
|
|
|
|
|
import (
|
|
|
"encoding/json"
|
|
|
- "errors"
|
|
|
+ "fmt"
|
|
|
"net/url"
|
|
|
"time"
|
|
|
|
|
@@ -69,7 +69,7 @@ func (mc *MiniClient) getToken() (token string, err error) {
|
|
|
if err != nil {
|
|
|
return
|
|
|
}
|
|
|
- token = mc.AccessToken
|
|
|
+ token = ct.AccessToken
|
|
|
return
|
|
|
}
|
|
|
|
|
@@ -181,7 +181,7 @@ func (mc *MiniClient) GetPhoneInfo(frm FormCode) (res MiniPhoneInfo, err error)
|
|
|
}
|
|
|
|
|
|
if res.ErrCode != 0 {
|
|
|
- err = errors.New(res.ErrMsg)
|
|
|
+ err = fmt.Errorf("%s uri: %s", res.ErrMsg, uri)
|
|
|
}
|
|
|
|
|
|
return
|