From 65c5c5c461aa2a0551881774a16e4273c2d11023 Mon Sep 17 00:00:00 2001 From: Shravya Ramesh Date: Fri, 19 Mar 2021 10:02:31 -0700 Subject: adjusted find friends --- src/components/profile/Friends.tsx | 67 ++++++++++++++++++-------------------- 1 file changed, 32 insertions(+), 35 deletions(-) (limited to 'src/components') diff --git a/src/components/profile/Friends.tsx b/src/components/profile/Friends.tsx index 0f5596d5..51ba6c64 100644 --- a/src/components/profile/Friends.tsx +++ b/src/components/profile/Friends.tsx @@ -86,42 +86,39 @@ const Friends: React.FC = ({result, screenType, userId}) => { return ( <> - {loggedInUser.userId === userId || - (userId === undefined && ( - - - Add Friends - { - const permission = await checkPermission(); - if (permission === 'authorized') { - navigation.navigate('InviteFriendsScreen', { - screenType: ScreenType.Profile, - }); - } else { - Alert.alert( - '"Tagg" Would Like to Access Your Contacts', - 'This helps you quickly get in touch with friends on the app and more', - [ - { - text: "Don't Allow", - style: 'cancel', - }, - {text: 'Allow', onPress: () => Linking.openSettings()}, - ], - ); - } - }}> - - - Find Friends - - - - + {loggedInUser.userId === userId && ( + + + Add Friends + { + const permission = await checkPermission(); + if (permission === 'authorized') { + navigation.navigate('InviteFriendsScreen', { + screenType: ScreenType.Profile, + }); + } else { + Alert.alert( + '"Tagg" Would Like to Access Your Contacts', + 'This helps you quickly get in touch with friends on the app and more', + [ + { + text: "Don't Allow", + style: 'cancel', + }, + {text: 'Allow', onPress: () => Linking.openSettings()}, + ], + ); + } + }}> + + Find Friends + - ))} + + + )} Friends -- cgit v1.2.3-70-g09d2