type renamed to ad_type