- Issue created by @yobottehg
- Open on Drupal.org →Core: 9.5.x + Environment: PHP 7.3 & MySQL 5.7last update
about 1 year ago Waiting for branch to pass - Issue was unassigned.
- Status changed to Needs review
about 1 year ago 9:00am 24 November 2023
Facets changed how they handle empty facets. jsonapi_search_api_facets has some code which also tackles this problem in AddSearchMetaEventSubscriber:79
This fails now with the latest dev release of facets if the search has no results.
"TypeError: reset(): Argument #1 ($array) must be of type array, bool given in /app/cms/web/modules/contrib/jsonapi_search_api/modules/jsonapi_search_api_facets/src/EventSubscriber/AddSearchMetaEventSubscriber.php:79
https://git.drupalcode.org/project/facets/-/commit/a903026303868cd0a901c...
Only reset the array if it is an array.
Needs review
1.0
Code