fix: if user is unsubscribed, and shouldn't show paywall, send message without running IGC (#1344)

pull/1593/head
ggurdin 11 months ago committed by GitHub
parent f4e9823384
commit 317cf88aca
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -87,9 +87,12 @@ class Choreographer {
return;
}
if (pangeaController.subscriptionController.subscriptionStatus ==
SubscriptionStatus.showPaywall) {
OverlayUtil.showPositionedCard(
if (!pangeaController.subscriptionController.isSubscribed) {
// don't want to run IGC if user isn't subscribed, so either
// show the paywall if applicable or just send the message
final status = pangeaController.subscriptionController.subscriptionStatus;
status == SubscriptionStatus.showPaywall
? OverlayUtil.showPositionedCard(
context: context,
cardToShow: PaywallCard(
chatController: chatController,
@ -97,7 +100,8 @@ class Choreographer {
maxHeight: 325,
maxWidth: 325,
transformTargetId: inputTransformTargetKey,
);
)
: chatController.send();
return;
}

Loading…
Cancel
Save