WIP: Undefined array key

I am getting:

[12-Nov-2024 21:13:00 UTC] PHP Warning:  Undefined array key "optionMetaValue" in /bricks/includes/elements/filter-base.php on line 431
[12-Nov-2024 21:13:04 UTC] PHP Warning:  Undefined array key "optionMetaValue" in /bricks/includes/elements/filter-base.php on line 431

in my error log. Not sure if I did something!

Hi @yasmine ,

Thanks for reporting the issue.
Recorded this in the bug tracker. Will be fixed soon.

Regards,
Jenn

1 Like

Hi Yasmine,
We’ve fixed this issue in Bricks 1.11.1.1, now available as a one-click update in your WordPress Dashboard.

Changelog: Bricks 1.11.1.1 Changelog – Bricks

Please let us know if you are still experiencing issues.

Best regards,
timmse

1 Like

Thank you!! But my error_log is now flagging another undefined array key in the same function:

[17-Nov-2024 22:47:27 UTC] PHP Warning:  Undefined array key "optionLabel" in /bricks/includes/elements/filter-base.php on line 434

Thanks

Hi there,

Can you help to check or provide some screenshots of all your Filter - elements where using “Custom Field” as source + “Custom” Label? I need to check your Custom Label mapping data.

Alternatively, please provide admin access and send it to help@bricksbuilder.io (Include this forum thread URL as reference)

Regards,
Jenn

Sure! I have 6:






And then I have this one which is not yet in use as I still can’t get it working, so perhaps this one is the issue:

The last one is a cloneable group field - so actually probably the culprit for the array. And I did not do any label mapping :
Screenshot 2024-11-18 at 13.13.09

Hi @yasmine ,

Thanks for the screenshots.

Am I right that custom label mapping is not meant for any label mapping right?

Kindly remove or change the Label to “Value” to avoid that error message.

I can replicate this error and will fix it.

Regards,
Jenn

Oh I now understand what the label mapping is for. It is a key to change the labels of option values. I did not understand what was supposed to do with that! Sorry for my error!

But I also cannot see the values in order to change them. In my case I would assume the values would be true and false ? I wanted a filter that if a value exists then to list just them. So an example would be:
“Includes bonus” // For where ‘bonus’ exists
“Show all” //For every value, bonus or no bonus.

When you use an “exist”, are the values 1/true or 0/false ? Or is it just a true statement? Because I actually would not want to include the false statement, as I can use the “All” option as an alternative to the false. Because there would not (in this case) be a scenario where you need the false.

I hope this makes sense. I think I am trying to understand where you can see the values of a condition in order to map them!

Hi @yasmine ,

Unfortunately, label mapping is not meant for your scenario.
You want to group options but this is not possible in Bricks Query Filters.

Label mapping is meant for user who created custom fields to store values in integer (0, 1,2,)
Without mapping, visitor can only see 0, 1, 2 as the filter options.

With mapping, now user can map like
0 => “Off”
1 => “Ready”
2 = > “Completed”

Regards,
Jenn

Ok thank you. I understand now the purpose of label.

When I do academicrecommendation_multiple EXISTS

academicrecommendation_multiple being a group field ID.

And it does not show any options, except the “All” - which it shows.

If I understand you correctly it is because I am trying to check the existence of a group field, which you cannot do?