Added validation in JS for signUp and signIn