mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-16 23:13:50 +08:00
Don't show two errors in verificationCode login page
This commit is contained in:
@ -588,6 +588,10 @@ class LoginPage extends React.Component {
|
||||
},
|
||||
{
|
||||
validator: (_, value) => {
|
||||
if (value === "") {
|
||||
return Promise.resolve();
|
||||
}
|
||||
|
||||
if (this.state.loginMethod === "verificationCode") {
|
||||
if (!Setting.isValidEmail(value) && !Setting.isValidPhone(value)) {
|
||||
this.setState({validEmailOrPhone: false});
|
||||
|
Reference in New Issue
Block a user