Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash - dataIntent must not be null #477

Closed
AlgirdasVZ opened this issue Jul 2, 2019 · 1 comment
Closed

Crash - dataIntent must not be null #477

AlgirdasVZ opened this issue Jul 2, 2019 · 1 comment

Comments

@AlgirdasVZ
Copy link

Hi!

Looks like some react-native-app-auth users are still facing this issue. I'm forwarding it here - it might be useful to find out whether this issue somehow could be solved on the react-native-app-auth library itself or only on AppAuth-Android where crash is triggered.

original issue thread: FormidableLabs/react-native-app-auth#130

Crash scenario:

  1. Open the app
  2. Start authorizing - login page is displayed in browser
  3. Put the app in background
  4. Start the app again from the device launcher
  5. App user sees "Critical Error Occured!" with crashlogs

Fatal Exception: java.lang.RuntimeException Failure delivering result ResultInfo{who=null, request=0, result=0, data=null} to activity {<app's Main Activity>}: java.lang.NullPointerException: dataIntent must not be null
...
net.openid.appauth.Preconditions.checkNotNull + 55 (Preconditions.java:55) net.openid.appauth.AuthorizationResponse.fromIntent + 564 (AuthorizationResponse.java:564) com.rnappauth.RNAppAuthModule.onActivityResult + 303 (RNAppAuthModule.java:303)

Crash is avoided if on step 4 the app is resumed instead of relaunched.

Note: in this case, AndroidManifest.xml contains android:launchMode="singleTask"

@tarun29061990
Copy link

Is this fixed??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants