isActive method

bool isActive()

Return true if there is at least one purchase that unlocked this entitlement. It's possible the user didn't purchase a SKU on user's current device platform but they did make a transaction on a different device platform. To enable the entitlement under this context, activePurchases will have at least one item to activate the entitlement.

Implementation

bool isActive() {
  return purchasedSKUs.isNotEmpty || activePurchases.isNotEmpty;
}