diff options
Diffstat (limited to 'src/services/UserProfileService.ts')
| -rw-r--r-- | src/services/UserProfileService.ts | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/services/UserProfileService.ts b/src/services/UserProfileService.ts index e69e4103..c8dbcdd1 100644 --- a/src/services/UserProfileService.ts +++ b/src/services/UserProfileService.ts @@ -1,10 +1,8 @@ -//Abstracted common profile api calls out here - import AsyncStorage from '@react-native-community/async-storage'; import moment from 'moment'; import {Alert} from 'react-native'; import RNFetchBlob from 'rn-fetch-blob'; -import {SocialAccountType, MomentType} from 'src/types'; +import {SocialAccountType} from 'src/types'; import { AVATAR_PHOTO_ENDPOINT, COVER_PHOTO_ENDPOINT, @@ -25,10 +23,9 @@ export const loadProfileInfo = async (token: string, userId: string) => { const status = response.status; if (status === 200) { const info = await response.json(); - let {name, biography, website, birthday, gender} = info; - // user should always have a birthday, but a safety check here + let {name, biography, website, birthday, gender, snapchat, tiktok} = info; birthday = birthday && moment(birthday).format('YYYY-MM-DD'); - return {name, biography, website, birthday, gender}; + return {name, biography, website, birthday, gender, snapchat, tiktok}; } } catch (error) { Alert.alert( |
