Skip to content

Adds ObjC inits for Paywalls-only in UIKit#6507

Merged
JayShortway merged 2 commits into
mainfrom
objc-purchase-logic
Mar 23, 2026
Merged

Adds ObjC inits for Paywalls-only in UIKit#6507
JayShortway merged 2 commits into
mainfrom
objc-purchase-logic

Conversation

@JayShortway

@JayShortway JayShortway commented Mar 23, 2026

Copy link
Copy Markdown
Member

Motivation

As far as I could tell we didn't have any ObjC-compatible way to provide custom purchase logic to UIKit Paywalls.

This PR adds a PaywallPurchaseHandler protocol and accepts it in PaywallViewController and PaywallFooterViewController.


Note

Medium Risk
Adds new public Objective-C facing API surface and async bridging from callback-based handlers into existing purchase/restore closures; issues would primarily affect custom purchase/restore flows when apps complete purchases themselves.

Overview
Adds an Objective-C compatible PaywallPurchaseHandler protocol and new @objc initializers on PaywallViewController and PaywallFooterViewController that accept it for custom purchase/restore behavior.

Introduces bridging logic (bridgePurchaseHandler) to convert the handler’s callback-based API into the existing async performPurchase/performRestore closures, and updates Swift/ObjC API tester targets to validate the new initializers and protocol exposure.

Written by Cursor Bugbot for commit ca60b66. This will update automatically on new commits. Configure here.

@JayShortway JayShortway self-assigned this Mar 23, 2026
@JayShortway JayShortway added the pr:feat A new feature label Mar 23, 2026
@JayShortway JayShortway changed the title Objc purchase logic Adds ObjC inits for Paywalls-only in UIKit Mar 23, 2026
@JayShortway JayShortway marked this pull request as ready for review March 23, 2026 17:37
@JayShortway JayShortway requested a review from a team as a code owner March 23, 2026 17:37

@rickvdl rickvdl left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! Thanks for adding 🙌

@JayShortway JayShortway merged commit 20b204c into main Mar 23, 2026
38 checks passed
@JayShortway JayShortway deleted the objc-purchase-logic branch March 23, 2026 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr:feat A new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants