去除验证码注释
This commit is contained in:
parent
00e42df556
commit
c979a70b3a
@ -218,22 +218,28 @@ class LoginService extends BaseService
|
||||
}
|
||||
}
|
||||
|
||||
// 手机号登陆
|
||||
public function mobileLogin(){
|
||||
/**
|
||||
* 手机号登陆
|
||||
* @return array
|
||||
* @throws ContainerExceptionInterface
|
||||
* @throws NotFoundExceptionInterface
|
||||
*/
|
||||
public function mobileLogin(): array
|
||||
{
|
||||
$code = $this->request->input('code');
|
||||
$phone = $this->request->input('phone');
|
||||
$user_type = $this->request->input('user_type');
|
||||
|
||||
$redis = $this->container->get(Redis::class);
|
||||
// 验证验证码
|
||||
// $sms_code = $redis->get("login_code" . $phone);
|
||||
// if (empty($sms_code)){
|
||||
// return fail(HttpEnumCode::CODE_EXPIRED);
|
||||
// }
|
||||
//
|
||||
// if ($sms_code != $code){
|
||||
// return fail(HttpEnumCode::CODE_ERROR);
|
||||
// }
|
||||
$sms_code = $redis->get("login_code" . $phone);
|
||||
if (empty($sms_code)){
|
||||
return fail(HttpEnumCode::CODE_EXPIRED);
|
||||
}
|
||||
|
||||
if ($sms_code != $code){
|
||||
return fail(HttpEnumCode::CODE_ERROR);
|
||||
}
|
||||
|
||||
Db::beginTransaction();
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user