Patch for code that is not following best practices in Magento development#46
Closed
IvanChepurnyi wants to merge 4 commits intomagento:masterfrom
EcomDev:master
Closed
Patch for code that is not following best practices in Magento development#46IvanChepurnyi wants to merge 4 commits intomagento:masterfrom EcomDev:master
IvanChepurnyi wants to merge 4 commits intomagento:masterfrom
EcomDev:master
Conversation
…o use more appropriate load() method of the model.
There was a problem hiding this comment.
Collection method getItemById returns object instance if found and null otherwise.
Your code will return Mage_Sales_Model_Order_Address instance in any case.
So you need to change if statement to be something like this:
if ($address->getId() !== null)
Contributor
Author
There was a problem hiding this comment.
if ($address->getId()) is enough, just 10 lines of code later the similar construction is used.
…problem is visible if you have additional custom totals that need to be placed in between core ones.
…hp, to move them into separate branch
Contributor
Author
|
Closed in favor of #48 |
magento-team
pushed a commit
that referenced
this pull request
Jan 23, 2015
[Firedrakes] Bugfixes. Sprint 35
Closed
Closed
This was referenced Nov 22, 2015
magento-engcom-team
pushed a commit
that referenced
this pull request
May 30, 2021
MC-42057: Fix jQuery.fn.resize()
5 tasks
1 task
5 tasks
5 tasks
5 tasks
5 tasks
Closed
5 tasks
5 tasks
5 tasks
5 tasks
5 tasks
5 tasks
Closed
5 tasks
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
See attached commit, where using of collection for retrieving address by id is replaced by using of standard load method of the model.