Remove declared properties accessed by magic getter in Paypal Config #2759
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description (*)
In #2554, properties which were being set dynamically were added as class properties to support PHP 8.2. However in the case of
app/code/core/Mage/Paypal/Model/Config.php
, there is a magic getter (conveniently hidden in the center of the file 👀) which was accessing the properties from the paypal configuration which never gets called if the property is already declared on the class.Related Pull Requests
Fixed Issues (if relevant)
Manual testing scenarios (*)
Questions or comments
app/code/core/Mage/Paypal/Model/Config.php
will need to be refactored to get rid of dynamic properties assignment, but as that can take more time and can potentially be breaking, I choose to just undo that change until we decide later.Contribution checklist (*)