Commit d489164e by 邓实川

登录验证码bug修改

parent 2395b94e
...@@ -254,9 +254,10 @@ public class LoginController { ...@@ -254,9 +254,10 @@ public class LoginController {
String phone = entRegisterDto.getPhone(); String phone = entRegisterDto.getPhone();
String code = entRegisterDto.getCode().toString(); String code = entRegisterDto.getCode().toString();
// String codeRedis = (String) redisTemplate.get(phone); // String codeRedis = (String) redisTemplate.get(phone);
Integer codeRedis = (Integer) session.getAttribute(phone); String codeRedis = session.getAttribute(phone).toString();
System.err.println(code);
if (code == null || !code.equals(codeRedis.toString())) { System.err.println(codeRedis);
if (code == null || !code.equals(codeRedis)) {
return ResultUtil.error("验证码不符"); return ResultUtil.error("验证码不符");
} }
return ResultUtil.success("验证码正确"); return ResultUtil.success("验证码正确");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment