I've tried reindexing, updating the products, setup:upgrade, etc and none of this seems to work.

2 Answers 2


This issue has already been resolved in Magento 2.4-develop branch. To apply the fix, apply this patch: https://github.com/magento/magento2/commit/a9170022cce29993e586ffaa6f4c1cc357ee3b11.diff

Related commit: https://github.com/magento/magento2/commit/a9170022cce29993e586ffaa6f4c1cc357ee3b11

Related pull request: https://github.com/magento/magento2/pull/35986/

There is another issue: the number of total items in the toolbar is incorrect. Magento (Adobe) has published a patch for this issue:
ACSD-48234: catalog search result shows incorrect category item count Display Out of Stock Products enabled https://experienceleague.adobe.com/docs/commerce-knowledge-base/kb/support-tools/patches/v1-1-25/acsd-48234-catalog-search-result-shows-incorrect-category-item-count-when-show-out-of-stock-option-enabled.html?lang=en

You can apply it via the Quality Patches Tool (QPT) or via composer patch file: https://github.com/magento/quality-patches/tree/master/patches/os searching for "ACSD-48234"

  • Thank you for the solution. But I have changed in vendor/magento/module-elasticsearch/Model/ResourceModel/Fulltext/Collection/SearchResultApplier.php and it is working fine. Can you let me know how to I override this file? Thank you Oct 20, 2022 at 9:14
  • I tried like this /app/code/Magento/Elasticsearch/Model/ResourceModel/Fulltext/Collection/SearchResultApplier.php but not working. Oct 20, 2022 at 9:16
  • I strongly recommend you apply this patch via composer. Here is the document from Magento: experienceleague.adobe.com/docs/commerce-operations/… If you need help, feel free to let me know.
    – Tu Van
    Oct 20, 2022 at 10:58
  • Thank you :) It is working fine. Oct 31, 2022 at 12:41
  • Glad to hear that.
    – Tu Van
    Oct 31, 2022 at 12:47


1. Total count in the toolbar is wrong


Create a patch to disable the update_toolbar_count plugin.

Core file: vendor/magento/module-inventory-catalog/etc/di.xml

<type name="Magento\Catalog\Block\Product\ProductList\Toolbar">
        disabled="true" />

2. Show per page dropdown not working


Create a patch


            <?php if ($block->isLimitCurrent($_key)):?>
            <?php endif ?>>
-           <?= $block->escapeHtml($localeFormatter->formatNumber((int) $_limit)) ?>
+           <?= $block->escapeHtml(
+               is_numeric($_limit) ? $localeFormatter->formatNumber((int) $_limit) : $_limit
+           ) ?>
    <?php endforeach; ?>

Ref: https://github.com/magento/magento2/commit/bb55549cd3016987663272e7ffe3f452c8d6e40d

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.