fix($state): fix StateQueueManager orphan detection

StateQueueManager was bailing on states it deemed orphaned if it saw them in consecutive iterations.  However, if a state is orphaned a few levels deep, it may take multiple iterations before its parent tree is built.