mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Make named capture groups compatible with older PCRE versions.
CentOS is terrible and generally contains very old versions of PCRE. Update patterns to use more backwards compatible named capture groups. Fixes #3821
This commit is contained in:
parent
de5b25e352
commit
b533c1b3ba
1 changed files with 1 additions and 1 deletions
|
@ -170,7 +170,7 @@ class Hash {
|
|||
*/
|
||||
protected static function _matches(array $data, $selector) {
|
||||
preg_match_all(
|
||||
'/(\[ (?<attr>[^=><!]+?) (\s* (?<op>[><!]?[=]|[><]) \s* (?<val>(?:\/.*?\/ | [^\]]+)) )? \])/x',
|
||||
'/(\[ (?P<attr>[^=><!]+?) (\s* (?P<op>[><!]?[=]|[><]) \s* (?P<val>(?:\/.*?\/ | [^\]]+)) )? \])/x',
|
||||
$selector,
|
||||
$conditions,
|
||||
PREG_SET_ORDER
|
||||
|
|
Loading…
Reference in a new issue