question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

The app hangs when buyProduct() has an error

See original GitHub issue

Version 1.0.8

If I have a line like this, this will never get returned - it hangs. In my case the error is responseCode: 7(ITEM_ALREADY_OWNED)

const purchase = await RNIap.buyProduct(productId);

I think this is an unwanted side effect caused by this commit. You probably should at least resolve the promise if you do not want to reject it. https://github.com/dooboolab/react-native-iap/commit/d74846c4e0e6bbf65e3a4a1749aa675a53bf1724#diff-b21dbc2d57e14bf6f1b5f81c3a3c3ba5R309

What do you think?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
hyochancommented, Jun 10, 2018

I’ve publshed your PR to 1.1.2. I will close this for now.

0reactions
wasedaigocommented, Jun 10, 2018

I can help with PR at some pint, but I need to know what you would like to do.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Review Crashes - Invalid Product I… | Apple Developer Forums
From time to time, App Reviews of in app purchase apps will fail when the SKProductsRequest is made to preflight (validate) the in...
Read more >
App crashes with in-app purchase error - ios - Stack Overflow
You have to use viewWillDissappear() function for that in your billing controller. Try that one . override func viewWillDisappear(_ ...
Read more >
View crashes and application not responding (ANR) errors
Using Play Console, you can view data for crashes and application not responding (ANR) errors for your apps. Data comes from Android devices...
Read more >
iOS App Hangs Can Finally Be Fixed With Bugsnag
When an iOS app is unresponsive, users encounter an app freeze or app hang. No action can be taken as the user often...
Read more >
Detect and diagnose crashes - Android Developers
When an app crashes, Android terminates the app's process and displays a dialog to let the user know that the app has stopped, ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found