Skip to main content
Question

Check subscription status show random true or false

  • April 23, 2022
  • 1 reply
  • 40 views

Forum|alt.badge.img+2

Hi, after i buy my subscription, purchaserInfo show sometimes indicates a purchase, sometimes not

 

With Android Emulator / Flutter

 

Here is my code to check

 checkPremium() async {
    Purchases.addPurchaserInfoUpdateListener((purchaserInfo) async {
      PurchaserInfo purchaserInfo = await Purchases.getPurchaserInfo();
      (purchaserInfo.entitlements.all["remove_ads"] != null &&
              purchaserInfo.entitlements.all["remove_ads"]!.isActive)
          ? print("Active")
          : print("Not Active");

      setState(() {});
    });
  }

 

 

sundeep
RevenueCat Staff
Forum|alt.badge.img+8
  • RevenueCat Staff
  • May 2, 2022

Hi @MArcel, can you share more what you mean by “randomly true or false” (can you share debug logs illustrating this - https://docs.revenuecat.com/docs/debugging#debugging)? It’s expected in sandbox for subscriptions to renew and expire at an accelerated pace, so that might be why you’re seeing entitlements active and then not active minutes later.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings