|
|
|
@ -12,6 +12,7 @@ import org.springframework.beans.factory.annotation.Value;
|
|
|
|
|
import org.springframework.data.redis.core.RedisTemplate;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
|
|
|
|
import java.util.Objects;
|
|
|
|
|
import java.util.UUID;
|
|
|
|
|
import java.util.concurrent.TimeUnit;
|
|
|
|
|
|
|
|
|
@ -79,7 +80,7 @@ public class VerificationCodeServiceImpl implements VerificationCodeService {
|
|
|
|
|
return new CheckPhoneVerificationCodeVO(VerificationCodeConstant.VERIFICATION_CODE_TIMEOUT);
|
|
|
|
|
} else {
|
|
|
|
|
String verificationCode = verificationCodeRedis.getVerificationCode();
|
|
|
|
|
if (StringUtil.equal(verificationCode, passengerVerificationCode.getVerificationCode())) {
|
|
|
|
|
if (Objects.equals(verificationCode, passengerVerificationCode.getVerificationCode())) {
|
|
|
|
|
this.redisTemplate.delete(VerificationCodeConstant.PASSENGER_PHONE_VERIFICATION_CODE_PREFIX + verificationToken);
|
|
|
|
|
return new CheckPhoneVerificationCodeVO(VerificationCodeConstant.VERIFICATION_CODE_RIGHT, verificationCodeRedis.getPassengerPhone());
|
|
|
|
|
} else {
|
|
|
|
|