There doesn't seem to be any reason to define this outside of the loop.