记得上下班打卡 | git大法好,push需谨慎

Commit 79f16905 authored by 张国柄's avatar 张国柄

check code config: dev,test;

parent 7bacdba1
......@@ -34,6 +34,7 @@ import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletRequest;
import java.nio.charset.StandardCharsets;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
......@@ -221,7 +222,7 @@ public class AdamLoginController {
/* ---------------------------- Internal Method ---------------------------- */
private boolean checkSmsCode(String mobile, String code) {
if ("dev".equals(environment.getProperty("spring.profiles.active")) && "111111".equals(code)) {
if (Arrays.asList("dev", "test").contains(environment.getProperty("spring.profiles.active")) && "111111".equals(code)) {
return true;
}
......
......@@ -207,7 +207,7 @@ public class AdamUserController {
/* ---------------------------- Internal Method ---------------------------- */
private boolean checkSmsCode(String mobile, String code) {
if ("dev".equals(environment.getProperty("spring.profiles.active")) && "111111".equals(code)) {
if (Arrays.asList("dev", "test").contains(environment.getProperty("spring.profiles.active")) && "111111".equals(code)) {
return true;
}
......
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