Skip to main content

i am using react native in ios it is working fine ,but in android it is not working .could any one help me.

but in android other react iap is working 

 

componentDidMount() {

      Purchases.setDebugLogsEnabled(true);
      Purchases.setup("****************************");

}

================

version i have used

==============
  "react-native": "~0.63.4",
  "react-native-purchases": "^4.3.0",
============

error i am getting ,showing it s not connecting with RC but it is working with IAP other pacages

==================

null is not an object (evaluating 'RNPurchases.setDebugLogsEnabled')
at node_modules/react-native-purchases/dist/purchases.js:335:19 in Purchases.setDebugLogsEnabled
at App.js:23:4 in componentDidMount
at App.js:21:2 in componentDidMount
at tnative code]:null in commitRootImpl
at lnative code]:null in performSyncWorkOnRoot
at node_modules/react-native/Libraries/ReactNative/renderApplication.js:54:4 in renderApplication
at node_modules/react-native/Libraries/ReactNative/AppRegistry.js:117:25 in runnables.appKey.run
at node_modules/react-native/Libraries/ReactNative/AppRegistry.js:202:4 in runApplication
at nnative code]:null in callFunctionReturnFlushedQueue

--

pEdited]: RC Staff has edited this post to redact additional information.

Hi @Michele Laurelli,

For the null is not an object (evaluating 'RNPurchases.setDebugLogsEnabled') in the stack trace, it looks like the SDK wasn’t installed correctly. Can you try removing the package and installing it again?

You can also try building the sample app to confirm it’s not a problem with any code on your side. As well as double checking the install guide.


Reply