Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/rename product to payment with quantity #202

Merged
merged 3 commits into from
May 10, 2017

Conversation

bizz84
Copy link
Owner

@bizz84 bizz84 commented May 10, 2017

Fix for #200.

This is an API breaking change

Product renamed to Purchase (+ added quantity):

public struct Purchase {
    public let productId: String
    public let quantity: Int
    public let transaction: PaymentTransaction
    public let needsFinishTransaction: Bool
}

PurchaseResult

From this:

public enum PurchaseResult {
    case success(product: Product)
    case error(error: SKError)
}

to this:

public enum PurchaseResult {
    case success(purchase: Purchase)
    case error(error: SKError)
}

RestoreResults

From this:

public struct RestoreResults {
    public let restoredProducts: [Product]
    public let restoreFailedProducts: [(SKError, String?)]
}

to this:

public struct RestoreResults {
    public let restoredPurchases: [Purchase]
    public let restoreFailedPurchases: [(SKError, String?)]
}

@bizz84 bizz84 merged commit 69cb8a3 into develop May 10, 2017
@bizz84 bizz84 deleted the feature/rename-product-to-payment-with-quantity branch May 10, 2017 14:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant