Fix random crash in SubscriptionFragment
This commit is contained in:
parent
977fe2e3e5
commit
c14f366d32
1 changed files with 6 additions and 0 deletions
|
|
@ -422,6 +422,12 @@ class SubscriptionFragment : BaseStateFragment<SubscriptionState>() {
|
||||||
feedGroupsSortMenuItem.showSortButton = groups.size > 1
|
feedGroupsSortMenuItem.showSortButton = groups.size > 1
|
||||||
feedGroupsSortMenuItem.listViewMode = listViewMode
|
feedGroupsSortMenuItem.listViewMode = listViewMode
|
||||||
binding.itemsList.post {
|
binding.itemsList.post {
|
||||||
|
if (context == null) {
|
||||||
|
// since this part was posted to the next UI cycle, the fragment might have been
|
||||||
|
// removed in the meantime
|
||||||
|
return@post
|
||||||
|
}
|
||||||
|
|
||||||
feedGroupsCarousel.notifyChanged(FeedGroupCarouselItem.PAYLOAD_UPDATE_LIST_VIEW_MODE)
|
feedGroupsCarousel.notifyChanged(FeedGroupCarouselItem.PAYLOAD_UPDATE_LIST_VIEW_MODE)
|
||||||
feedGroupsSortMenuItem.notifyChanged(GroupsHeader.PAYLOAD_UPDATE_ICONS)
|
feedGroupsSortMenuItem.notifyChanged(GroupsHeader.PAYLOAD_UPDATE_ICONS)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue