russell-archer / StoreHelper

Implementing In-App Purchases with StoreKit2 in Xcode 13 - 15 using SwiftUI, Swift 5.7 - 5.9, iOS 15 - 17 and macOS 12 - 14. Also supports tvOS and visionOS.
MIT License
410 stars 48 forks source link

Add detailed error when making purchase #46

Closed Hengyu closed 1 year ago

Hengyu commented 1 year ago

The throwing error would be either PurchaseError or StoreKitError.

We add the detailed error into the exception so that the app is able to display comprehensive text to user when their purchase failed.

@russell-archer

russell-archer commented 1 year ago

Great idea. Thanks very much for the PR!

Hengyu commented 1 year ago

Thanks @russell-archer for quick review! By the way, would u mind to create a release tag for the commit? it would be cool if I can use it directly in my project now

russell-archer commented 1 year ago

Done!