observePurchaseError

fun observePurchaseError(product: ProductDetails, error: Throwable)(source)

Convenience method to observe purchase errors.

Call this method when a purchase fails to track the failure in Superwall's analytics. This will trigger tracking of the Transaction Fail event.

Parameters

product

The Google Play Billing ProductDetails for the product that failed to purchase

error

The error that caused the purchase to fail