set user_type appropriately