add a condition before deleting double_indirects blocks