Last active
December 21, 2015 21:07
-
-
Save mcavaliere/b257f4236c9a9c5b0176 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var element = $("div.form-errors"); | |
if (formHasErrors()) { | |
element.show(); | |
} | |
// More, unrelated code... | |
var element = $("form#login"); | |
element.addClass("has-errors"); | |
// Another block of code... | |
$("input.submit").on("click", function() { | |
element.remove(); | |
// ... | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment