changed type to user_type