Skip to content

Commit c7b8b2c

Browse files
committed
Merge branch 'release/2.6.4'
2 parents 5b9104b + 8e46812 commit c7b8b2c

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Cryptomator/Purchase/PurchaseViewModel.swift

+5-1
Original file line numberDiff line numberDiff line change
@@ -93,8 +93,12 @@ class PurchaseViewModel: BaseIAPViewModel, ProductFetching {
9393

9494
private func addLifetimeLicenseItem() {
9595
if let product = products[.fullVersion], let localizedPrice = product.localizedPrice {
96+
// Temporarily added for December 2024 Sale
97+
let currentYear = Calendar.current.component(.year, from: Date())
98+
let currentMonth = Calendar.current.component(.month, from: Date())
99+
let productDetail = currentYear == 2024 && currentMonth == 12 ? "🎁 33%* off in December" : nil
96100
let viewModel = PurchaseCellViewModel(productName: LocalizedString.getValue("purchase.product.lifetimeLicense"),
97-
productDetail: "🎁 33%* off in December",
101+
productDetail: productDetail,
98102
price: localizedPrice,
99103
purchaseDetail: LocalizedString.getValue("purchase.product.lifetimeLicense.duration"),
100104
productIdentifier: .fullVersion)

CryptomatorTests/Purchase/PurchaseViewModelTests.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ class PurchaseViewModelTests: IAPViewModelTestCase {
169169

170170
private var lifetimeLicenseCell: Item {
171171
return .purchaseCell(.init(productName: LocalizedString.getValue("purchase.product.lifetimeLicense"),
172-
productDetail: "🎁 33%* off in December",
172+
productDetail: nil,
173173
price: "$11.99",
174174
purchaseDetail: LocalizedString.getValue("purchase.product.lifetimeLicense.duration"),
175175
productIdentifier: .fullVersion))

0 commit comments

Comments
 (0)