implemented more functionality for user registration and email confirmation