Armature Edit mode has its own undo handling, which didn't store the
number of root bone collections in the armature. Now it does.
An alternative would be to not store this in the undo step, but rather
loop over all bone collections to find the minimum `child_index`. This
would be linear in the number of bone collections, though, so I chose to
use a few more bytes of memory to make the undo system a little faster.