diff --git a/app/components/channel_actions/add_people_box/add_people_box.tsx b/app/components/channel_actions/add_people_box/add_people_box.tsx index 345a3a3af6..6ed83fe0d2 100644 --- a/app/components/channel_actions/add_people_box/add_people_box.tsx +++ b/app/components/channel_actions/add_people_box/add_people_box.tsx @@ -20,11 +20,11 @@ type Props = { } const AddPeopleBox = ({channelId, containerStyle, displayName, inModal, testID}: Props) => { - const intl = useIntl(); + const {formatMessage} = useIntl(); const theme = useTheme(); const onAddPeople = useCallback(async () => { - const title = intl.formatMessage({id: 'mobile.channel_add_people.title', defaultMessage: 'Add Members'}); + const title = formatMessage({id: 'mobile.channel_add_people.title', defaultMessage: 'Add Members'}); const options = { topBar: { subtitle: { @@ -39,7 +39,7 @@ const AddPeopleBox = ({channelId, containerStyle, displayName, inModal, testID}: } await dismissBottomSheet(); showModal(Screens.CHANNEL_ADD_PEOPLE, title, {channelId}); - }, [intl, channelId, inModal]); + }, [formatMessage, channelId, inModal]); return ( ); };