-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
chore: Optimize the usage of option 'baseURI' for CURLRequest #9274
Conversation
Just like in your previous PR: removing properties from the class or adding required parameters to the existing methods is considered a BC break. |
@michalsn Emmm... Now that 'there is no need to worry about deprecating anything',why could not us deprecate the property 'baseURI' of CURLRequest? |
@warmbook I was talking about In your code, you're simply removing things without a good reason, which is not acceptable. |
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.
If you wanted to fix it, all you need to do is replace $options['baseURI'] ?? null
Thanks! I've got it. But how could I submit the left suggestions? I mean, I have some idea about this framework apart from fixing this bug. @michalsn @neznaika0 |
Enhancements and new features can be sent to the Just remember that any breaking changes must have a really good reason to be accepted. Backward compatibility is preferred. |
Thanks! I've got it. @michalsn |
#9265
Description
Use option 'baseURI' first in Config\Services->curlrequest.
Use the property 'uri' of OutgoingRequest as default baseURI instead of the property 'baseURI' of CURLRequest.
Remove the property 'baseURI' of CURLRequest.
Nolonger parse 'baseURI' in 'parseOptions' method.
If 'baseURI' exists in 'request' method's options, create a new URI instance with it. Otherwise, use the property 'uri' of OutgoingRequest.
Use the param '$uri' passed in rather than the property 'baseURI' of CURLRequest in 'prepareURL' method.
Remove 'getBaseURI' method from Test/Mock/MockCURLRequest.
Checklist: