Adapty iOS SDK を v3.15 に移行する
オブザーバーモードでペイウォールビルダーを使用している場合、iOS SDK 3.15 以降では新しいメソッド observerModeDidInitiateRestorePurchases(onStartRestore:onFinishRestore:) を実装する必要があります。このメソッドにより、リストアロジックをより細かく制御できるようになり、カスタムフローで購入のリストアを処理できます。実装の詳細については、オブザーバーモードでペイウォールビルダーのペイウォールを表示するを参照してください。
func observerMode(didInitiatePurchase product: AdaptyPaywallProduct,
onStartPurchase: @escaping () -> Void,
onFinishPurchase: @escaping () -> Void) {
// use the product object to handle the purchase
// use the onStartPurchase and onFinishPurchase callbacks to notify AdaptyUI about the process of the purchase
}
+ func observerModeDidInitiateRestorePurchases(onStartRestore: @escaping () -> Void,
+ onFinishRestore: @escaping () -> Void) {
+ // use the onStartRestore and onFinishRestore callbacks to notify AdaptyUI about the process of the restore
+ }