last_item_index should be incremented at the end o...
# suitescript
a
last_item_index should be incremented at the end of the loop, not beginning