-
Notifications
You must be signed in to change notification settings - Fork 85
Resubscribe if cancelled #2487
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resubscribe if cancelled #2487
Conversation
📸 Snapshot Test648 unchanged
🛸 Powered by Emerge Tools |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, looks good!
private fun transformPathsOnSubscriptionState( | ||
paths: List<HelpPath>, | ||
selectedPurchaseInformation: PurchaseInformation?, | ||
localization: CustomerCenterConfigData.Localization, | ||
): List<HelpPath> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor, but we can make paths
the receiver, so we don't need the let
above:
private fun List<HelpPath>.transformPathsOnSubscriptionState(
selectedPurchaseInformation: PurchaseInformation?,
localization: CustomerCenterConfigData.Localization,
): List<HelpPath> {
(You can press Option+Enter with your caret in the paths
parameter, and click "Convert parameter to receiver" to do it automatically.)
@@ -122,7 +121,7 @@ class CustomerCenterViewModelTests { | |||
} | |||
|
|||
@Test | |||
fun `loadAndDisplayPromotionalOffer returns false when offer is not eligible`() = runTest { | |||
fun `loadAndDisplayPromotionalOffer returns false when offer is not eligible`(): Unit = runBlocking { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!!
...com/revenuecat/purchases/ui/revenuecatui/customercenter/viewmodel/CustomerCenterViewModel.kt
Outdated
Show resolved
Hide resolved
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2487 +/- ##
==========================================
- Coverage 78.10% 78.09% -0.01%
==========================================
Files 286 286
Lines 10573 10575 +2
Branches 1485 1485
==========================================
+ Hits 8258 8259 +1
- Misses 1668 1669 +1
Partials 647 647 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
**This is an automatic release.** ## RevenueCat SDK ### 🐞 Bugfixes * Resubscribe if cancelled (#2487) via Cesar de la Vega (@vegaro) ### Virtual Currency #### 🐞 Bugfixes * Update VC Caching Log Message (#2552) via Will Taylor (@fire-at-will) ## RevenueCatUI SDK ### Customer Center #### 🐞 Bugfixes * Update design of No Active subscriptions screen in Customer Center (#2559) via Cesar de la Vega (@vegaro) ### 🔄 Other Changes * [AUTOMATIC][Paywalls V2] Updates paywall-preview-resources submodule (#2561) via RevenueCat Git Bot (@RCGitBot) * [AUTOMATIC][Paywalls V2] Updates paywall-preview-resources submodule (#2560) via RevenueCat Git Bot (@RCGitBot) * Bump danger from 9.5.1 to 9.5.3 (#2556) via dependabot[bot] (@dependabot[bot]) * Bump fastlane from 2.227.2 to 2.228.0 (#2557) via dependabot[bot] (@dependabot[bot]) * Bump fastlane-plugin-revenuecat_internal from `9a29f63` to `7d97553` (#2558) via dependabot[bot] (@dependabot[bot]) * [AUTOMATIC][Paywalls V2] Updates paywall-preview-resources submodule (#2555) via RevenueCat Git Bot (@RCGitBot) * Bump nokogiri from 1.18.8 to 1.18.9 (#2553) via dependabot[bot] (@dependabot[bot]) * [AUTOMATIC][Paywalls V2] Updates paywall-preview-resources submodule (#2551) via RevenueCat Git Bot (@RCGitBot) * Fix paywall tester so customer center doesn't close when changing to dark mode (#2550) via Cesar de la Vega (@vegaro) Co-authored-by: revenuecat-ops <ops@revenuecat.com>
If the subscription is already cancelled, it should say "Resubscribe" instead of "Cancel Subscription" It should also not open any feedback survey or promotional offer
If the subscription is already cancelled, it should say "Resubscribe" instead of "Cancel Subscription"
It should also not open any feedback survey or promotional offer