I have an iOS app. Some UIViewControllers have automatically updated content, it means that app can get update (simple JSON) any time (but no more often than about 1 time in half an hour). View controllers have UICollectionView with UIContextMenu for iOS >= 13.0.
Some times arises a situation when the user has called the context menu, but the content of cell and its menu are no longer relevant. UICollectionView already reloaded (with resorting cells), but context menu still shown.
I know when the update happens in my app and I want to dismiss open menu in this moment.
So my question is - how to dismiss context menu programmatically?
Thanks for any help!