add: next index to toArray