User Registration and Login Fix

fixed the null exception thrown when trying to create an account