-
Notifications
You must be signed in to change notification settings - Fork 401
Restore Old Package & Offering Initializer APIs #5474
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
base: main
Are you sure you want to change the base?
Conversation
📸 Snapshot Test1 modified, 704 unchanged
🛸 Powered by Emerge Tools |
|
@RCGitBot please test |
tonidero
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good! Just a couple of non-blocker comments.
|
|
||
| /// Initialize an ``Offering`` given a list of ``Package``s. | ||
| @objc | ||
| public convenience init( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder, should we deprecate these constructors? Not sure if we want to push devs into just a single constructor... Maybe we should even try to make the "main" constructor internal to avoid these issues but we would need to keep the current ones public for backwards compatibility
JZDesign
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
closes #5460
Context
In release 5.23.0, we unintentionally broke the public API for the
OfferingandPackageinitializers by adding a non-optionalwebCheckoutUrl: URL?parameter.The breaking changes were introduced in the these PRs/commits:
Description
This PR restores the previous API by re-introducing new public initializers for these structs that omit the webCheckoutUrl parameter, matching the API contracts prior to 5.23.0. It also adds these re-introduced constructors to the API testers.
This PR introduces entirely new convenience initializers rather than adding a default value of nil to the existing ones, because initializers with default parameter values aren’t exposed to Objective-C. Simply adding a default would not restore the original Objective-C API.