Permalink
Browse files

Omit optional validUntil parameter on ViewController

  • Loading branch information...
bizz84 committed Dec 30, 2017
1 parent 7af1d35 commit f19dcaba333f2e96a01f47974ded0663eaad792d
Showing with 6 additions and 14 deletions.
  1. +3 −8 SwiftyStoreKit-iOS-Demo/ViewController.swift
  2. +3 −6 SwiftyStoreKit-macOS-Demo/ViewController.swift
@@ -189,23 +189,18 @@ class ViewController: UIViewController {
let purchaseResult = SwiftyStoreKit.verifySubscription(
ofType: .autoRenewable,
productId: productId,
inReceipt: receipt,
validUntil: Date()
)
inReceipt: receipt)
self.showAlert(self.alertForVerifySubscriptions(purchaseResult, productIds: [productId]))
case .nonRenewingPurchase:
let purchaseResult = SwiftyStoreKit.verifySubscription(
ofType: .nonRenewing(validDuration: 60),
productId: productId,
inReceipt: receipt,
validUntil: Date()
)
inReceipt: receipt)
self.showAlert(self.alertForVerifySubscriptions(purchaseResult, productIds: [productId]))
default:
let purchaseResult = SwiftyStoreKit.verifyPurchase(
productId: productId,
inReceipt: receipt
)
inReceipt: receipt)
self.showAlert(self.alertForVerifyPurchase(purchaseResult, productId: productId))
}
@@ -130,21 +130,18 @@ class ViewController: NSViewController {
let purchaseResult = SwiftyStoreKit.verifySubscription(
ofType: .autoRenewable,
productId: productId,
inReceipt: receipt
)
inReceipt: receipt)
self.showAlert(self.alertForVerifySubscription(purchaseResult))
case .nonRenewingPurchase:
let purchaseResult = SwiftyStoreKit.verifySubscription(
ofType: .nonRenewing(validDuration: 60),
productId: productId,
inReceipt: receipt
)
inReceipt: receipt)
self.showAlert(self.alertForVerifySubscription(purchaseResult))
default:
let purchaseResult = SwiftyStoreKit.verifyPurchase(
productId: productId,
inReceipt: receipt
)
inReceipt: receipt)
self.showAlert(self.alertForVerifyPurchase(purchaseResult))
}

0 comments on commit f19dcab

Please sign in to comment.