State restoration issue when restoring a presented view controller