Skip to content

Commit

Permalink
Merge pull request #52863 from etCoderDysto/switcher_back
Browse files Browse the repository at this point in the history
fix: navigate to switcher when clicking back button after creating a workspace from switcher
  • Loading branch information
cristipaval authored Nov 26, 2024
2 parents 2719015 + 057d2ca commit 084a711
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import * as Illustrations from '@components/Icon/Illustrations';
import Section, {CARD_LAYOUT} from '@components/Section';
import useLocalize from '@hooks/useLocalize';
import useThemeStyles from '@hooks/useThemeStyles';
import Navigation from '@libs/Navigation/Navigation';
import * as App from '@userActions/App';

function WorkspaceCardCreateAWorkspace() {
Expand All @@ -21,7 +22,8 @@ function WorkspaceCardCreateAWorkspace() {
>
<Button
onPress={() => {
App.createWorkspaceWithPolicyDraftAndNavigateToIt();
const activeRoute = Navigation.getActiveRouteWithoutParams();
App.createWorkspaceWithPolicyDraftAndNavigateToIt('', '', false, false, activeRoute);
}}
text={translate('workspace.emptyWorkspace.createAWorkspaceCTA')}
style={styles.mt5}
Expand Down

0 comments on commit 084a711

Please sign in to comment.