Validation failures when referencing a view with brackets in the name

Created on 19 October 2023, about 1 year ago
Updated 14 June 2024, 5 months ago

When a view contains brackets in the name saving Views Reference fields fail.

This is because when saving a view the view ID is extracted from the view name with the view ID included in brackets at the end with e regex that doesn't take into account there might be brackets in the view name.

My proposed fix for this is to use `preg_match_all` rather than `preg_match` and take the last matched value.

🐛 Bug report
Status

Closed: duplicate

Version

2.0

Component

Code

Created by

🇬🇧United Kingdom stephen-cox

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

Comments & Activities

Production build 0.71.5 2024