new user object and refactoring