You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (!isFlushSuccessful) {
console.log('No failed purchases cached as pending.');
// Handle the case where there are no failed purchases cached as pending
} else {
console.log('Failed purchases cached as pending flushed successfully.');
}
}
const products = await RNIap.getProducts({skus: productSkus});
console.log('-products----------->->->->', productSkus, products);
return products;
const productSkus = Platform.select({
ios: ['abc', 'abc2'],
android: ['abc', 'abc2'],
default: [],
});
export const getAllPurchasePlans = async productSkus => {
try {
await RNIap.initConnection();
// Flush failed purchases cached as pending on Android
if (Platform.OS === 'android') {
const isFlushSuccessful =
await RNIap.flushFailedPurchasesCachedAsPendingAndroid();
} catch (error) {
//console.error('Error fetching products:', error);
return [];
}
};
this is my code but its always return me empty array have any solution so please share here....
The text was updated successfully, but these errors were encountered: