Skip to content

Commit

Permalink
Merge pull request #12586 from asineath-onpoint/fix/abide-validateInp…
Browse files Browse the repository at this point in the history
…ut-remove-cleared-errors

fix: Abide validateInput - remove existing error classes before adding error classes
  • Loading branch information
joeworkman authored Sep 27, 2024
2 parents 344a897 + ee0ece4 commit 130e7f7
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions js/foundation.abide.js
Original file line number Diff line number Diff line change
Expand Up @@ -510,10 +510,9 @@ class Abide extends Plugin {
}

if (manageErrorClasses) {
this.removeErrorClasses($el);
if (!goodToGo) {
this.addErrorClasses($el, failedValidators);
} else {
this.removeErrorClasses($el);
this.addErrorClasses($el, failedValidators);
}
}

Expand Down

0 comments on commit 130e7f7

Please sign in to comment.