1 Added condition to check if profile exists in doLogin and show methods

Bulk of code has to do with the login and register processes for the users. Let me know if you have any questions.