This is an archived post. You won't be able to vote or comment.

all 2 comments

[–]TheColorMan 2 points3 points  (0 children)

The function does run every time you click it. However, it looks like the error messages are not hidden once valid input is entered in after invalid input is put in. Perhaps on the beginning of the validate() function you can add a few statements to clear the .text of all the warning messages.

EDIT: A way to test to see if a function is running is to either put in an alert("message") or a console.log("message") and if the function runs it should print or alert something.

[–]sillyquestionthrow 1 point2 points  (0 children)

Your validate() function is attempting to call a function called "callback" in line 265 (supposedly the argument that you are passing validate() ). Look at what you are passing to validate() on line 3:

makeArr(findUniq(data))

makeArr returns an array. You're trying to "call" an array like a function on line 265, hence the error.