_patch_ad moved to utils