[Android] Fix getInitialLink() is NULL

This commit is contained in:
Bilal Syed 2018-07-11 15:30:35 +03:00
parent 98ca66294d
commit c70af86e2e
1 changed files with 5 additions and 1 deletions

View File

@ -174,7 +174,11 @@ public class RNFirebaseLinks extends ReactContextBaseJavaModule implements Activ
// Looks at the internals of the link data to detect whether it's an invitation or not // Looks at the internals of the link data to detect whether it's an invitation or not
private boolean isInvitation(PendingDynamicLinkData pendingDynamicLinkData) { private boolean isInvitation(PendingDynamicLinkData pendingDynamicLinkData) {
return FirebaseAppInvite.getInvitation(pendingDynamicLinkData) != null; FirebaseAppInvite invite = FirebaseAppInvite.getInvitation(pendingDynamicLinkData);
if (invite != null && invite.getInvitationId() != null && !invite.getInvitationId().isEmpty()) {
return true;
}
return false;
} }
private DynamicLink.Builder getDynamicLinkBuilder(final ReadableMap linkData) { private DynamicLink.Builder getDynamicLinkBuilder(final ReadableMap linkData) {