Skip to content

Commit

Permalink
more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ggurdin committed Jan 16, 2024
1 parent 59e22d1 commit 00bf461
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion lib/pangea/controllers/class_controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class ClassController extends BaseController {
try {
//question for gabby: why do we need this in two places?
if (!_pangeaController.subscriptionController.isSubscribed) {
debugPrint("Unsubscribed user in class_controller. Showing paywall.");
print("Unsubscribed user in class_controller. Showing paywall.");
_pangeaController.subscriptionController.showPaywall(context);
}
} catch (err) {
Expand Down
14 changes: 7 additions & 7 deletions lib/pangea/controllers/subscription_controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ class SubscriptionController extends BaseController {
subscription?.currentSubscription?.isTrial ?? false;

Future<void> initialize() async {
debugPrint("Initializing subscription controller");
print("Initializing subscription controller");
try {
if (_pangeaController.matrixState.client.userID == null) {
debugPrint(
print(
"Attempted to initalize subscription information with null userId",
);
return;
Expand All @@ -60,15 +60,15 @@ class SubscriptionController extends BaseController {
? WebSubscriptionInfo(pangeaController: _pangeaController)
: MobileSubscriptionInfo(pangeaController: _pangeaController);

debugPrint("Configuring subscription controller");
print("Configuring subscription controller");
await subscription!.configure();
debugPrint("Configured subscription controller");
print("Configured subscription controller");

if (activatedNewUserTrial) {
setNewUserTrial();
}

debugPrint("Setting initalized true");
print("Setting initalized true");
initialized = true;

if (!kIsWeb) {
Expand All @@ -94,7 +94,7 @@ class SubscriptionController extends BaseController {
}
setState();
} catch (e, s) {
debugPrint("Failed to initialize subscription controller");
print("Failed to initialize subscription controller");
ErrorHandler.logError(e: e, s: s);
}
}
Expand Down Expand Up @@ -136,7 +136,7 @@ class SubscriptionController extends BaseController {
BuildContext context, [
bool forceShow = false,
]) async {
debugPrint(
print(
"User is not subscribed. Showing paywall. Initialized: $initialized",
);
try {
Expand Down

0 comments on commit 00bf461

Please sign in to comment.