This `if` block could go outside the loop, avoiding doing the test for each feature.