diff --git a/src/components/ScreenWrapper.tsx b/src/components/ScreenWrapper.tsx index 7a551492aea4..1be36cc4d2ed 100644 --- a/src/components/ScreenWrapper.tsx +++ b/src/components/ScreenWrapper.tsx @@ -206,10 +206,8 @@ function ScreenWrapper( } // We always need the safe area padding bottom if we're showing the offline indicator since it is bottom-docked. - if (includeSafeAreaPaddingBottom || (isOffline && shouldShowOfflineIndicator)) { - if (!shouldDisableSafeAreaPaddingBottom) { - paddingStyle.paddingBottom = paddingBottom; - } + if (!shouldDisableSafeAreaPaddingBottom && (includeSafeAreaPaddingBottom || (isOffline && shouldShowOfflineIndicator))) { + paddingStyle.paddingBottom = paddingBottom; } return ( diff --git a/src/libs/Navigation/linkTo.ts b/src/libs/Navigation/linkTo.ts index ffed34dca2b4..9b4a2515623c 100644 --- a/src/libs/Navigation/linkTo.ts +++ b/src/libs/Navigation/linkTo.ts @@ -74,7 +74,7 @@ function getActionForBottomTabNavigator(action: StackNavigationAction, state: Na const screen = params.screen; // Check if the current bottom tab is the same as the one we want to navigate to. If it is, we don't need to do anything. - const bottomTabCurrentTab = bottomTabNavigatorRoute.state.routes.at(bottomTabNavigatorRoute.state.index ?? 0); + const bottomTabCurrentTab = getTopmostBottomTabRoute(state); if (bottomTabCurrentTab?.name === screen) { return; }