Fixed for loop for iterating through trips.