|
@@ -607,7 +607,6 @@ func (this *UserAccount) PhoneBind() {
|
|
|
err error
|
|
|
)
|
|
|
captchaKey := this.GetString("captchaKey") //图形验证码key
|
|
|
- log.Println("captchaKey:", captchaKey)
|
|
|
if captchaKey != "" {
|
|
|
if strings.TrimSpace(phone) == "" {
|
|
|
return nil, fmt.Errorf("手机号异常")
|
|
@@ -616,10 +615,8 @@ func (this *UserAccount) PhoneBind() {
|
|
|
return nil, fmt.Errorf("已绑定手机号,请勿重复绑定")
|
|
|
}
|
|
|
identCode := this.GetString("identCode") //短信验证码
|
|
|
- log.Println("identCode:", identCode)
|
|
|
- captchaPhone := jy.CheckPhoneIdent(this.Session(), identCode, fmt.Sprintf(jycaptcha.SendCodeKey, captchaKey, phone))
|
|
|
- log.Println("captchaPhone:", captchaPhone)
|
|
|
- if phone != captchaPhone { //验证码不正确
|
|
|
+ phoneVerify = jy.CheckPhoneIdent(this.Session(), identCode, fmt.Sprintf(jycaptcha.SendCodeKey, captchaKey, phone))
|
|
|
+ if phone != phoneVerify { //验证码不正确
|
|
|
return nil, fmt.Errorf("验证码错误")
|
|
|
}
|
|
|
} else {
|