Skip to content

Instantly share code, notes, and snippets.

@abbas-oveissi
Last active December 7, 2019 09:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abbas-oveissi/d799168cddb0dcf0b777f772f1479e09 to your computer and use it in GitHub Desktop.
Save abbas-oveissi/d799168cddb0dcf0b777f772f1479e09 to your computer and use it in GitHub Desktop.
private void consumeDownloadPurchase(Purchase purchase) {
mHelper.consumeAsync(purchase, new IabHelper.OnConsumeFinishedListener() {
@Override
public void onConsumeFinished(Purchase purchase, IabResult result) {
if (result.isFailure()) {
Toast.makeText(DetailActivity.this, R.string.purchasing_error, Toast.LENGTH_SHORT).show();
return;
}
startDownloading();
}
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment