From 18d6e1bfd045fbd6a17861737b10fcd056e7bd80 Mon Sep 17 00:00:00 2001 From: vilson <545522390@qq.com> Date: Fri, 22 Feb 2019 10:38:12 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=B7=A8=E5=9F=9F=E4=B8=8B?= =?UTF-8?q?=E6=97=A0=E6=B3=95=E4=BD=BF=E7=94=A8=E6=AD=A3=E5=B8=B8=E4=BD=BF?= =?UTF-8?q?=E7=94=A8=E7=9F=AD=E4=BF=A1=E9=AA=8C=E8=AF=81=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98=E3=80=81=E7=89=88=E6=9C=AC=E6=9B=B4=E6=96=B0=E8=87=B3?= =?UTF-8?q?2.2.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: vilson <545522390@qq.com> --- application/project/controller/Login.php | 16 ++++++++-------- config/app.php | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/application/project/controller/Login.php b/application/project/controller/Login.php index 8e5577a..b053200 100644 --- a/application/project/controller/Login.php +++ b/application/project/controller/Login.php @@ -69,10 +69,10 @@ class Login extends BasicApi // 用户信息验证 $mobile = $this->request->post('mobile', ''); if ($mobile) { - if (session('captcha') != Request::param('captcha')) { + if (cache('captcha') != Request::param('captcha')) { $this->error('验证码错误', 203); } - if (session('captchaMobile') != $mobile) { + if (cache('captchaMobile') != $mobile) { $this->error('手机号与验证码不匹配', 203); } $member = \app\common\Model\Member::where(['mobile' => $mobile])->order('id asc')->find(); @@ -134,8 +134,8 @@ class Login extends BasicApi $this->error('系统繁忙'); } } - session('captcha', $code); - session('captchaMobile', $mobile); + cache('captcha', $code); + cache('captchaMobile', $mobile); $this->success('', config('sms.debug') ? $code : ''); } @@ -170,10 +170,10 @@ class Login extends BasicApi if ($member) { $this->error('该手机已被注册', 202); } - if (session('captcha') != $data['captcha']) { + if (cache('captcha') != $data['captcha']) { $this->error('验证码错误', 203); } - if (session('captchaMobile') != $data['mobile']) { + if (cache('captchaMobile') != $data['mobile']) { $this->error('手机号与验证码不匹配', 203); } $memberData = [ @@ -206,10 +206,10 @@ class Login extends BasicApi public function _bindMobile() { $mobile = $this->request->post('mobile', ''); - if (session('captcha') != Request::param('captcha')) { + if (cache('captcha') != Request::param('captcha')) { $this->error('验证码错误', 203); } - if (session('captchaMobile') != $mobile) { + if (cache('captchaMobile') != $mobile) { $this->error('手机号与验证码不匹配', 203); } $member = getCurrentMember(); diff --git a/config/app.php b/config/app.php index 01fb324..20e0b81 100644 --- a/config/app.php +++ b/config/app.php @@ -6,7 +6,7 @@ return [ // 应用名称 'app_name' => 'pearProject', // 应用版本 - 'app_version' => '2.2.2', + 'app_version' => '2.2.3', // 应用地址 'app_host' => '', // 应用调试模式