Fixed bugs associated with User class