fixed a bunch of issues, user registration & validate inputs