修复通过手机号码登录时验证码错误问题
Signed-off-by: vilson <545522390@qq.com>
This commit is contained in:
parent
b412ec17ce
commit
46541e8f91
@ -76,12 +76,12 @@ class Login extends BasicApi
|
|||||||
// 用户信息验证
|
// 用户信息验证
|
||||||
$mobile = $this->request->post('mobile', '');
|
$mobile = $this->request->post('mobile', '');
|
||||||
if ($mobile) {
|
if ($mobile) {
|
||||||
if (cache('captcha') != Request::param('captcha')) {
|
if (cache('captcha:' . $mobile) != Request::param('captcha')) {
|
||||||
$this->error('验证码错误', 203);
|
$this->error('验证码错误', 203);
|
||||||
}
|
}
|
||||||
if (cache('captchaMobile') != $mobile) {
|
// if (cache('captchaMobile') != $mobile) {
|
||||||
$this->error('手机号与验证码不匹配', 203);
|
// $this->error('手机号与验证码不匹配', 203);
|
||||||
}
|
// }
|
||||||
$member = Member::where(['mobile' => $mobile])->order('id asc')->find();
|
$member = Member::where(['mobile' => $mobile])->order('id asc')->find();
|
||||||
} else {
|
} else {
|
||||||
$member = Member::where(['account' => $data['account']])->whereOr(['email' => $data['account']])->order('id asc')->find();
|
$member = Member::where(['account' => $data['account']])->whereOr(['email' => $data['account']])->order('id asc')->find();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user