We previously did a `range` loop but since split-merge can materialize a node during a child split we could get in a situation where a child is added to the `n.children` list. The `range` operator only uses the original slice contents so that new child would be missed.

Also, we need to sort the children now since split-merge could move keys over to a node to the right and the node to the right could have been already flushed. Sorting the children makes sure that children get flushed in order.

One exception to this is that a node that has be materialized while being split-merged into will go to the end of the `n.children` list. This is ok since that node cannot split again.