Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Hide renew & expired sub hint when addon is active

Neeraj Gupta78ebd6a9f06e
diff --git a/apps/photos/src/components/Sidebar/SubscriptionStatus/index.tsx b/apps/photos/src/components/Sidebar/SubscriptionStatus/index.tsx
index 113228c34c..5fccc7291a 100644
--- a/apps/photos/src/components/Sidebar/SubscriptionStatus/index.tsx
+++ b/apps/photos/src/components/Sidebar/SubscriptionStatus/index.tsx
@@ -88,7 +88,8 @@ export default function SubscriptionStatus({
}}
/>
)
- ) : isSubscriptionCancelled(userDetails.subscription) ? (
+ ) : isSubscriptionCancelled(userDetails.subscription) &&
+ !hasAddOnBonus(userDetails.bonusData) ? (
t('RENEWAL_CANCELLED_SUBSCRIPTION_INFO', {
date: userDetails.subscription?.expiryTime,
})
@@ -105,12 +106,14 @@ export default function SubscriptionStatus({
)
)
) : (
- <Trans
- i18nKey={'SUBSCRIPTION_EXPIRED_MESSAGE'}
- components={{
- a: <LinkButton onClick={handleClick} />,
- }}
- />
+ !hasAddOnBonus(userDetails.bonusData) && (
+ <Trans
+ i18nKey={'SUBSCRIPTION_EXPIRED_MESSAGE'}
+ components={{
+ a: <LinkButton onClick={handleClick} />,
+ }}
+ />
+ )
)}
</Typography>
</Box>