-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
Fix #17933 - Bank Transfer Payment Instructions switch back to default #26765
Fix #17933 - Bank Transfer Payment Instructions switch back to default #26765
Conversation
Hi @Bartlomiejsz. Thank you for your contribution
For more details, please, review the Magento Contributor Guide documentation. |
5d097bf
to
8153cc6
Compare
if (!empty($methodInstance->getPayableTo())) { | ||
$payment->setAdditionalInformation('payable_to', $methodInstance->getPayableTo()); | ||
$storeId = $payment->getOrder()->getStoreId(); | ||
if (!empty($payableTo = $methodInstance->getConfigData('payable_to', $storeId))) { |
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 also used to implement assignments within comparisons but one day someone pointed me out that it can be a bit misleading: is the =
a real assignment or a bug, that is, a missing==
? Reading the code without too much attention (it happens) it may seem a bug, someone could be tempted to correct it causing indeed a bug :)
At that point, I stopped using it and switched back to assigning the variable and doing the comparison in two different statements.
Would you consider doing that change, thus joining my group of old, wise, and defensive programmers like me? :-)
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.
@aleron75 I'm not sure if I will get used to do it, but I can definitely try, changed it :)
8153cc6
to
b4dddf1
Compare
6872751
to
4543082
Compare
4543082
to
7c4be6a
Compare
@aleron75 I rebased changes on develop since those files were also modified there, ready for review again 😉 |
Hi @aleron75, thank you for the review. |
✔️ QA passed |
HI @aleron75 could you approve this PR once again to move it into |
Hi @aleron75, thank you for the review. |
…ack to default #26765
Hi @Bartlomiejsz, thank you for your contribution! |
Description (*)
This is fix for #17933
The issue was caused because observer modified here did override
additional_information
column insales_order_payment
table with data for incorrect store view.Also, exactly the same issue occurred for Cash On Delivery and very similar, just for other fields (
payable_to
andmailing_address
), for Check Money Order - both also are resolved with this fix.Related Pull Requests
Fixed Issues (if relevant)
Manual testing scenarios (*)
Please check fixed issue for testing scenario
Questions or comments
Contribution checklist (*)