Skip to main content
Question

addCustomerInfoUpdateListener is never called

  • 25 September 2022
  • 4 replies
  • 912 views

Forum|alt.badge.img+2

Using react-native-purchases v5.0.2 and I can’t seem to get Purchases.addCustomerInfoUpdateListener to fire when I make a purchase (it’s not a subscription in case that matters). Testing in both simulator and a device and neither seems to work.

I have a hook to track “premium” status and I want my tab view to automatically update when premium is unlocked from a different screen. I could hack in a manual call to `getCustomerInfo` when a screen regains focus but this is error prone so I’d really like to avoid it.

 

Also, in case it matters. The documentation mentions:

This will fire whenever we receive a change in purchaser info on the current device and you should expect it to be called at launch and throughout the life of the app.

But I’m not seeing it “called at launch” either.

 

Any help here is greatly appreciated.

4 replies

Forum|alt.badge.img+2
  • Author
  • New Member
  • 2 replies
  • October 4, 2022

Just wanted to bump this thread as I still can’t figure out why it isn’t working.


Forum|alt.badge.img+3
  • New Member
  • 1 reply
  • October 21, 2022

Hey,

 

I experienced the same issue, however, it was on Flutter. I started receiving updates from event listener once I updated to the latest version and changed to renamed APIs (https://github.com/RevenueCat/purchases-flutter/blob/main/CHANGELOG.md#renamed-apis).

 


Forum|alt.badge.img+2
  • New Member
  • 2 replies
  • November 11, 2022

Bump, I am also seeing this in React Native. I do not even see it called when I call getCustomerInfo


Forum|alt.badge.img+2
  • New Member
  • 2 replies
  • November 11, 2022

I opened a PR fixing this for react native I believe https://github.com/RevenueCat/react-native-purchases/pull/473


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings