I checked your code and it seems you have a logic error in your validation logic where you apply isEmpty
:
if(!Validator.isEmpty(data.handle)){
errors.handle ="Handle field is required";
}
if(!Validator.isEmpty(data.email)){
errors.email ="Email field is required";
}
It should be the other way around (note that you have this error for other fields as well, so check those too):
if(Validator.isEmpty(data.handle)){
errors.handle ="Handle field is required";
}
if(Validator.isEmpty(data.email)){
errors.email ="Email field is required";
}
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…