On iOS 15 builds created with Xcode 13, a collectionView is crashing when
collectionView.selectItem(at: indexPath, animated: false, scrollPosition: .top)
is called and it has no items in its datasource yet.
Crash Message:
Attempted to scroll the collection view to an out-of-bounds section (0) when there are only 0 sections.
Note
This does not happen on any builds created by versions of Xcode before Xcode 13.
Is this an expected change or something that needs to be addressed?
Selecting any option will automatically load the page