@@ -20,6 +20,7 @@ import useLocalize from '@hooks/useLocalize';
2020import useNetwork from '@hooks/useNetwork' ;
2121import useOnyx from '@hooks/useOnyx' ;
2222import useSafeAreaInsets from '@hooks/useSafeAreaInsets' ;
23+ import useSingleExecution from '@hooks/useSingleExecution' ;
2324import useThemeStyles from '@hooks/useThemeStyles' ;
2425import { navigateToAndOpenReport , searchInServer , setGroupDraft } from '@libs/actions/Report' ;
2526import { canUseTouchScreen } from '@libs/DeviceCapabilities' ;
@@ -173,6 +174,8 @@ function NewChatPage(_: unknown, ref: React.Ref<NewChatPageRef>) {
173174 const [ reportAttributesDerived ] = useOnyx ( ONYXKEYS . DERIVED . REPORT_ATTRIBUTES , { canBeMissing : true , selector : ( val ) => val ?. reports } ) ;
174175 const selectionListRef = useRef < SelectionListHandle | null > ( null ) ;
175176
177+ const { singleExecution} = useSingleExecution ( ) ;
178+
176179 useImperativeHandle ( ref , ( ) => ( {
177180 focus : selectionListRef . current ?. focusTextInput ,
178181 } ) ) ;
@@ -292,9 +295,11 @@ function NewChatPage(_: unknown, ref: React.Ref<NewChatPageRef>) {
292295 Log . warn ( 'Tried to create chat with empty login' ) ;
293296 return ;
294297 }
295- KeyboardUtils . dismiss ( ) . then ( ( ) => navigateToAndOpenReport ( [ login ] ) ) ;
298+ KeyboardUtils . dismiss ( ) . then ( ( ) => {
299+ singleExecution ( ( ) => navigateToAndOpenReport ( [ login ] ) ) ( ) ;
300+ } ) ;
296301 } ,
297- [ selectedOptions , toggleOption ] ,
302+ [ selectedOptions , toggleOption , singleExecution ] ,
298303 ) ;
299304
300305 const itemRightSideComponent = useCallback (
0 commit comments