Fix accidental changing of node order by callback function.