Skip to content

Commit

Permalink
Merge pull request #50772 from bernhardoj/fix/50098-submit-expense-pa…
Browse files Browse the repository at this point in the history
…ge-flickers-when-open

Fix money request page flickers when open
  • Loading branch information
marcaaron authored Oct 15, 2024
2 parents 67ceb7f + ce6861c commit 067e20f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/libs/Navigation/OnyxTabNavigator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,12 @@ function OnyxTabNavigator({
const state = event.data.state;
const index = state.index;
const routeNames = state.routeNames;
Tab.setSelectedTab(id, routeNames.at(index) as SelectedTabRequest);
onTabSelected(routeNames.at(index) as IOURequestType);
const newSelectedTab = routeNames.at(index);
if (selectedTab === newSelectedTab) {
return;
}
Tab.setSelectedTab(id, newSelectedTab as SelectedTabRequest);
onTabSelected(newSelectedTab as IOURequestType);
},
...(screenListeners ?? {}),
}}
Expand Down

0 comments on commit 067e20f

Please sign in to comment.