1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 22:10:45 +02:00

[ticket/13713] Escape special characters in preg_replace

PHPBB3-13713
This commit is contained in:
lavigor
2018-06-21 03:20:46 +03:00
committed by Marc Alexander
parent 659928f042
commit c6e9f001e3

View File

@@ -124,7 +124,7 @@ abstract class base_group implements source_interface
// Grab group data
$groups = $this->get_groups();
$matches = preg_grep('/^' . $keyword . '.*/i', $groups['names']);
$matches = preg_grep('/^' . preg_quote($keyword) . '.*/i', $groups['names']);
$group_ids = array_intersect($group_ids, array_flip($matches));
$names = [];