Fix validation js to show correct tab