cancel
Showing results for 
Search instead for 
Did you mean: 

Elasticsearch7 returns string but not array for the category page.

Elasticsearch7 returns string but not array for the category page.

When I tried to load my category page, the following error showing..

TypeError: Return value of Magento\Elasticsearch7\Model\Client\Elasticsearch::query() must be of the type array, string returned /hostname.local/app/code/Magento/Elasticsearch7/Model/Client/Elasticsearch.php:367

Versions details

  • Mac OS Big sure 11.2.x
  • MAMP Pro 6.3.1
  • Magento 2.4.2
  • Elasticsearch 7.12.0 (installed recently using Homebrew)

This issue is reported here before but there is no help at all.

I updated the Store->Configuration -> Catalog -> Catalog -> catalogSearch area in admin and the Test button returns Successfull.

Any kind of help will be appreciated..
Error page screengrab:
screencapture-carb2-local-index-php-supplied-html-2021-04-04-19_06_48.png