Wrong check removes nested filters completely

Created on 1 November 2024, 23 days ago

Problem/Motivation

https://git.drupalcode.org/project/search_api_swiftype/-/commit/321aea64... introduced a new check to skip nested filter processing, if there are no filters for a document type. Unfortunately the $nested_filters[$document_type] variable is no array there, but an object/stdClass - thus both is_array() and count() checks are failing and the nested filter is never added.

Steps to reproduce

  • Set up your index to contain a condition group with nested filter(s) and see those are never applied

Proposed resolution

  • Also handle the case that $nested_filters[$document_type] may be an object as well

Remaining tasks

  • Create issue fork and MR to fix this issue

User interface changes

n/a

API changes

n/a

Data model changes

n/a

🐛 Bug report
Status

Active

Version

10.0

Component

Code

Created by

🇩🇪Germany hctom

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024