1
This commit is contained in:
@@ -288,12 +288,17 @@ func (a *API) CheckImgIsSupplement(externalCustomerNo string) (*OpenCustomerExtI
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if imgSupplementResp.Code != "200" {
|
||||
if imgSupplementResp.Code != Success {
|
||||
return nil, fmt.Errorf(imgSupplementResp.Message)
|
||||
}
|
||||
|
||||
base64DecryData, _ := base64.StdEncoding.DecodeString(result["data"].(string))
|
||||
resultData, err := DecryptByPublicKey(base64DecryData, PublicKeyBegin)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
openCustomerExtImgVo := &OpenCustomerExtImgVo{}
|
||||
if err = json.Unmarshal([]byte(imgSupplementResp.Data), openCustomerExtImgVo); err != nil {
|
||||
if err = json.Unmarshal(resultData, openCustomerExtImgVo); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user