Wrong return type for getAttributeText($attributeCode) #11691
Labels
Fixed in 2.2.x
The issue has been fixed in 2.2 release line
Fixed in 2.3.x
The issue has been fixed in 2.3 release line
Issue: Confirmed
Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed
Issue: Format is valid
Gate 1 Passed. Automatic verification of issue format passed
Issue: Ready for Work
Gate 4. Acknowledged. Issue is added to backlog and ready for development
Reproduced on 2.1.x
The issue has been reproduced on latest 2.1 release
Reproduced on 2.2.x
The issue has been reproduced on latest 2.2 release
Reproduced on 2.3.x
The issue has been reproduced on latest 2.3 release
When I pass the a multi-select attribute code to
getAttributeText($attributeCode)
I get anarray
instead of anstring
.magento2/app/code/Magento/Catalog/Model/Product.php
Line 1717 in 4d26093
Actually I don't see anything wrong with it but the return tag should be updated accordingly.
Preconditions
Steps to reproduce
I guess the easiest way to reproduce it is by:
magento/module-catalog/view/frontend/templates/product/view/form.phtml
to output the attribute values:
Expected result
I would expect the return to be a
string
type as the return type says.Actual result
But the result is instead an
array
of attribute values.The text was updated successfully, but these errors were encountered: