Added some error handling for user creation