diff --git a/lib/models/user_details.dart b/lib/models/user_details.dart index ef1fdbbd7..f107a2e6b 100644 --- a/lib/models/user_details.dart +++ b/lib/models/user_details.dart @@ -33,6 +33,10 @@ class UserDetails { return familyData?.members?.isNotEmpty ?? false; } + bool hasPaidAddon() { + return bonusData?.getAddOnBonuses().isNotEmpty ?? false; + } + bool isFamilyAdmin() { assert(isPartOfFamily(), "verify user is part of family before calling"); final FamilyMember currentUserMember = familyData!.members! diff --git a/lib/services/billing_service.dart b/lib/services/billing_service.dart index 24ec308fb..6891089e3 100644 --- a/lib/services/billing_service.dart +++ b/lib/services/billing_service.dart @@ -166,7 +166,8 @@ class BillingService { BuildContext context, UserDetails userDetails, ) async { - if (userDetails.subscription.productID == freeProductID) { + if (userDetails.subscription.productID == freeProductID && + !userDetails.hasPaidAddon()) { await showErrorDialog( context, S.of(context).familyPlans,