-
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
magento/magento2: #8765 #8778
magento/magento2: #8765 #8778
Conversation
…nfig\SourceFactory::create() method is wrong Fixed type in return comment
A PHPDoc comment for \Magento\Config\Model\Config\SourceFactory::create() method is wrong The correct return parameter is \Magento\Framework\Option\ArrayInterface
Magento\Catalog\Model\ResourceModel\AbstractResource::getAttributeRawValue() returns false negative - fixed adding a strong check on return value
@@ -568,6 +568,6 @@ public function getAttributeRawValue($entityId, $attribute, $store) | |||
$attributesData = $_data[1]; | |||
} | |||
|
|||
return $attributesData ? $attributesData : false; | |||
return $attributesData!==false ? $attributesData : false; |
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.
Please add spaces around binary operator.
Also, as to me this statement would be less confusing if you invert condition (=== false
and swap ternary operator parts).
Magento\Catalog\Model\ResourceModel\AbstractResource::getAttributeRawValue() returns false negative - fixed adding a strong check on return value
@@ -568,6 +568,6 @@ public function getAttributeRawValue($entityId, $attribute, $store) | |||
$attributesData = $_data[1]; | |||
} | |||
|
|||
return $attributesData ? $attributesData : false; | |||
return $attributesData === false ? false: $attributesData; |
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! Just one more space in false:
left to add :)
It would be really nice if you squash all changes into one commit and force push into the same branch, but I do not insist on this.
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.
Fixed.. but i've still have some problem with squash :D
Magento\Catalog\Model\ResourceModel\AbstractResource::getAttributeRawValue() returns false negative - fixed adding a strong check on return value
@cavalier79 Thank you, accepted. |
M2.1.4 : Magento\Catalog\Model\ResourceModel\AbstractResource::getAttributeRawValue() returns false negative