Undefined array key "vid"

Created on 28 August 2023, over 1 year ago

Problem/Motivation

We get this issue when we select multiple taxonomies in view filter.

Steps to reproduce

Drupal view term filter only allows you to filter on terms from a single vocabulary. There is a patch to overcome this issue.
Issue link : https://www.drupal.org/project/drupal/issues/2784233 โœจ Allow multiple vocabularies in the taxonomy filter Needs work
When we apply patch, It change keys from "vid" to "vids". SHS module loading term based on vid.
It throws error for undefined key after applying patch.

Warning: Undefined array key "vid" in Drupal\shs\Plugin\views\filter\ShsTaxonomyIndexTid->valueForm() (line 48 of /usr/local/apache2/htdocs/web/modules/contrib/shs/src/Plugin/views/filter/ShsTaxonomyIndexTid.php)

Proposed resolution

Update the key from "vid" to "vids" and load multiple vocabularies.

๐Ÿ› Bug report
Status

Active

Version

2.0

Component

Code

Created by

๐Ÿ‡ฎ๐Ÿ‡ณIndia Harshit Ghediya

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