poiuytrez / AndroidInAppBilling

Android App Billing plugin for Cordova
173 stars 144 forks source link

Error "You already own this item" #80

Open simoneb opened 9 years ago

simoneb commented 9 years ago

Hi, I'm posting this question as an issue but it's more a problem in the documentation which is not very clear about what getPurchases does, or at least I cannot understand it. It says that it goes to the local database but it's not clear what happens if I but an item on one device and expect to have it on another device. To be clear, I think this is a fair expectation. So what I'm doing in my code is, when the item is needed, check if I already own it and if not trigger a purchase. The problem I'm facing is that at that point I get an error saying that I already own the item (because I bought it on another device).

So my question is, how can I check if I already own an item before trying to purchase it if not with getPurchases?