Why js adalat the contents of the second input email?

Check for correct email
$("input.email").change(function() { 
 var emailVal = $("input.email").val();
 var regex = new RegExp("^[-._a-z0-9]+@(?:[a-z0-9][-a-z0-9]+\.)+[a-z]{2,6}$");
 } else{

Let's say I have two forms on the same page in both the first normally he checks and the second with the same class only removes.
July 9th 19 at 11:11
1 answer
July 9th 19 at 11:13
You need inside the handler not to handle "input.email", and to this.

Find more questions by tags JavaScriptjQuery