We could remove some duplication here by combining this method with `delete_criteria` - they both do largely the same thing and are used together in the same places.