Move map.fitBounds call out of loop