This commit is contained in:
parent
8a33ea6707
commit
c2ef23b746
|
@ -20,7 +20,7 @@ class Api::V1::Users::UpdateEmailService < ApplicationService
|
||||||
def call
|
def call
|
||||||
raise Error, errors.full_messages.join(",") unless valid?
|
raise Error, errors.full_messages.join(",") unless valid?
|
||||||
raise Error, "密码不正确." unless @user.check_password?(@password)
|
raise Error, "密码不正确." unless @user.check_password?(@password)
|
||||||
if !(code == "123123" && EduSetting.get("code_debug")) # 万能验证码,用于测试 # TODO 万能验证码,用于测试
|
if !(@verify_code == "123123" && EduSetting.get("code_debug")) # 万能验证码,用于测试 # TODO 万能验证码,用于测试
|
||||||
raise Error, "验证码不正确." if @verify_code&.code != @code
|
raise Error, "验证码不正确." if @verify_code&.code != @code
|
||||||
raise Error, "验证码已失效." if !@verify_code&.effective?
|
raise Error, "验证码已失效." if !@verify_code&.effective?
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue