handling an edge case when encoding tag ids
adding a new state for RO to handle sub-collections