fix for devices without Firebase support

This commit is contained in:
Akinwale Ariwodola 2019-10-17 19:55:30 +01:00
parent 2bf67d31e8
commit e6ee26f94c
2 changed files with 6 additions and 6 deletions

View file

@ -55,7 +55,7 @@ export default class ModalTagSelector extends React.PureComponent {
return (
<TouchableOpacity style={modalTagSelectorStyle.overlay} activeOpacity={1} onPress={onOverlayPress}>
<View style={modalTagSelectorStyle.container}>
<TouchableOpacity style={modalTagSelectorStyle.container} activeOpacity={1}>
<View style={modalTagSelectorStyle.titleRow}>
<Text style={modalTagSelectorStyle.title}>Customize your tags</Text>
</View>
@ -75,7 +75,7 @@ export default class ModalTagSelector extends React.PureComponent {
<View style={modalTagSelectorStyle.buttons}>
<Button style={modalTagSelectorStyle.doneButton} text={'Done'} onPress={onDonePress} />
</View>
</View>
</TouchableOpacity>
</TouchableOpacity>
);
}

View file

@ -144,10 +144,10 @@ class SplashScreen extends React.PureComponent {
});
} else {
NativeModules.VersionInfo.getAppVersion().then(appVersion => {
NativeModules.Firebase.getMessagingToken().then(firebaseToken => {
this.setState({ shouldAuthenticate: true });
authenticate(appVersion, Platform.OS, firebaseToken);
});
this.setState({ shouldAuthenticate: true });
NativeModules.Firebase.getMessagingToken()
.then(firebaseToken => authenticate(appVersion, Platform.OS, firebaseToken))
.catch(() => authenticate(appVersion, Platform.OS));
});
}
})