magento/magento2#33588: strpos() expects parameter 1 to be string, ar…#40422
magento/magento2#33588: strpos() expects parameter 1 to be string, ar…#40422KrasnoshchokBohdan wants to merge 12 commits intomagento:2.4-developfrom
Conversation
… | magento/module-eav Handle missing 'label' key in advanced search dropdown attributes.
|
Hi @KrasnoshchokBohdan. Thank you for your contribution!
Allowed build names are:
You can find more information about the builds here For more details, review the Code Contributions documentation. |
|
@magento run all tests |
- Remove disallowed @author tag - Add explanation and @see tag to @deprecated annotation Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
@magento run all tests |
engcom-Hotel
left a comment
There was a problem hiding this comment.
Hello @KrasnoshchokBohdan,
Thank you for the contribution!
Please look into the failed tests and also look into the below review comment.
Thank you
|
|
||
| /** | ||
| * @deprecated 101.0.2 | ||
| * @deprecated 101.0.2 No alternative available. |
There was a problem hiding this comment.
This is something seems contradict, if there no alternative then I think we should remove @see annotation or vice versa.
… | magento/module-eav Remove deprecated catalog config property reference The `@see` annotation pointing to `Advanced::getAttributes()` was removed for the deprecated `_catalogConfig` property. This change cleans up irrelevant documentation for better code clarity.
|
@magento run all tests |
|
@magento run all tests |
|
@magento run all tests |
@engcom-Hotel @KrasnoshchokBohdan As this PR has been pending for quite some time, I’ve started addressing the review comments to help move it forward. |
|
@engcom-Hotel i have fixed the suggested review comment and static test failure. Could you please review the changes so we can further proceed with this PR? |
|
@magento run all tests |
|
As mentioned here #40422 (comment) the issue is not reproducible in Latest 2.4-develop instance Could you please let us know if we are missing anything till then moving to On Hold. Thanks. |
|
@engcom-Bravo Hi! I managed to reproduce it on 2.4-develop Screen.Recording.2026-04-17.at.17.04.17.movScreen.Recording.2026-04-17.at.17.07.49.mov |
|
@magento run Functional Tests B2B, Functional Tests CE, Functional Tests EE, Unit Tests |










Description (*)
Fixed a critical bug in the advanced search functionality where accessing dropdown/select attributes with array parameters causes a PHP warning "Undefined array key 'label'".
The issue occurred in
getPreparedSearchCriteria()method whengetOptionText()returns an array without a 'label' key. This happened when dropdown attributes were passed as URL array parameters (e.g.,color[]=49,50).Changes made:
??) on lines 405 and 412 inapp/code/Magento/CatalogSearch/Model/Advanced.phpto safely handle cases where the 'label' key doesn't exist in the array returned bygetOptionText()color_select_without_labelandcolor_multiselect_without_labelto prevent regressionRelated Pull Requests
Fixed Issues (if relevant)
Manual testing scenarios (*)
bin/magento cache:clean/catalogsearch/advanced/result/?color[]=49,50(where 49,50 - attr option ids)Questions or comments
Contribution checklist (*)