Skip to content

Commit

Permalink
fix: navigation without home tab enabled (#7046)
Browse files Browse the repository at this point in the history
  • Loading branch information
Pittvandewitt authored Feb 1, 2025
1 parent a3192c9 commit e3bf39f
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -354,11 +354,8 @@ class MainActivity : BaseActivity() {
}

override fun onMenuItemActionCollapse(item: MenuItem): Boolean {
// Handover back press to `BackPressedDispatcher`
if (binding.bottomNav.menu.children.none {
it.itemId == navController.currentDestination?.id
}
) {
// Handover back press to `BackPressedDispatcher` if not on a root destination
if (navController.previousBackStackEntry != null) {
this@MainActivity.onBackPressedDispatcher.onBackPressed()
}

Expand Down

0 comments on commit e3bf39f

Please sign in to comment.