bizz84 / bizz84/SwiftyStoreKit

User is being asked to enter Apple ID twice during the purchase

Open
#407 7 comments 0 reactions 0 assignees View on GitHub
Dominant language
Swift
Stars
6.7k
Forks
801
PR merge metrics
No merged PRs in 30d

Description

### Platform

- [x] iOS

### In app purchase type

- [x] Non-consumable
- [x] Auto-Renewable Subscription

### Environment

- [x] Sandbox

### Version

0.13.3

## Report

### Issue summary

I'm using the following snippet for the subscription purchases:
```
SwiftyStoreKit.purchaseProduct("my-product", quantity: 1, atomically: true) { result in
switch result {
case .success(let product):
if product.needsFinishTransaction {
SwiftyStoreKit.finishTransaction(product.transaction)
}
let appleValidator = AppleReceiptValidator(service: .production, sharedSecret: secret)

SwiftyStoreKit.verifyReceipt(using: appleValidator) { result in
switch result {
case .success(let receipt):
let purchaseResults = SwiftyStoreKit.verifySubscriptions(ofType: .autoRenewable, productIds: Set(subscriptionService.productIDs), inReceipt: receipt)

switch purchaseResults {
case .purchased(let expiryDate, let items):
...
```

Here I'm being asked for iTunes Store login twice. First when the purchase is being performed using `purchaseProduct ` and second when I'm retrieving subscriptions from the receipts using `verifyReceipt` and `verifySubscriptions`. It's going to be confusing for users to enter Apple ID twice. Has anyone else seen this behavior?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.