Refactored. Working on registration. Bug with password validation.