Simplify _.each by removing extra variable declarations