Updated loop/if/with to be more consistent
Merge pull request #2226 from Brancom/3.1

Updated loop/if/with to be more consistent