From 47fa79c466b4e5e4548b0f703f54f9be6e9a3c57 Mon Sep 17 00:00:00 2001 From: Taras Perun Date: Wed, 13 Dec 2023 10:27:07 +0100 Subject: [PATCH] fix after merge --- src/ROUTES.ts | 1 - src/SCREENS.ts | 4 ---- src/pages/settings/Profile/CustomStatus/StatusPage.js | 6 ++++-- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/src/ROUTES.ts b/src/ROUTES.ts index e0c7a16b4fd3..ca1fe9f0e81a 100644 --- a/src/ROUTES.ts +++ b/src/ROUTES.ts @@ -140,7 +140,6 @@ const ROUTES = { getRoute: (backTo?: string) => getUrlWithBackToParam('settings/security/two-factor-auth', backTo), }, SETTINGS_STATUS: 'settings/profile/status', - SETTINGS_STATUS_SET: 'settings/profile/status/set', SETTINGS_STATUS_CLEAR_AFTER: 'settings/profile/status/clear-after', SETTINGS_STATUS_CLEAR_AFTER_DATE: 'settings/profile/status/clear-after/date', SETTINGS_STATUS_CLEAR_AFTER_TIME: 'settings/profile/status/clear-after/time', diff --git a/src/SCREENS.ts b/src/SCREENS.ts index d4aa75e97538..2cd263237866 100644 --- a/src/SCREENS.ts +++ b/src/SCREENS.ts @@ -37,14 +37,10 @@ const SCREENS = { CONTACT_METHODS: 'Settings_ContactMethods', CONTACT_METHOD_DETAILS: 'Settings_ContactMethodDetails', NEW_CONTACT_METHOD: 'Settings_NewContactMethod', - STATUS_CLEAR_AFTER: 'Settings_Status_Clear_After', STATUS_CLEAR_AFTER_DATE: 'Settings_Status_Clear_After_Date', STATUS_CLEAR_AFTER_TIME: 'Settings_Status_Clear_After_Time', - STATUS: 'Settings_Status', - STATUS_SET: 'Settings_Status_Set', - PRONOUNS: 'Settings_Pronouns', TIMEZONE: 'Settings_Timezone', TIMEZONE_SELECT: 'Settings_Timezone_Select', diff --git a/src/pages/settings/Profile/CustomStatus/StatusPage.js b/src/pages/settings/Profile/CustomStatus/StatusPage.js index fce650ea23b2..1bf4165c15c5 100644 --- a/src/pages/settings/Profile/CustomStatus/StatusPage.js +++ b/src/pages/settings/Profile/CustomStatus/StatusPage.js @@ -1,6 +1,6 @@ import lodashGet from 'lodash/get'; import React, {useCallback, useEffect, useMemo, useRef, useState} from 'react'; -import {View} from 'react-native'; +import {InteractionManager, View} from 'react-native'; import {withOnyx} from 'react-native-onyx'; import EmojiPickerButtonDropdown from '@components/EmojiPicker/EmojiPickerButtonDropdown'; import FormProvider from '@components/Form/FormProvider'; @@ -86,7 +86,9 @@ function StatusPage({draftStatus, currentUserPersonalDetails}) { }); User.clearDraftCustomStatus(); - navigateBackToPreviousScreen(); + InteractionManager.runAfterInteractions(() => { + navigateBackToPreviousScreen(); + }); }, [currentUserClearAfter, draftClearAfter, isValidClearAfterDate, navigateBackToPreviousScreen], );