Skip to content

Commit

Permalink
narrowing search fields
Browse files Browse the repository at this point in the history
  • Loading branch information
Axel Stohn authored and Axel Stohn committed Jul 5, 2023
1 parent 1318fa4 commit a5d4048
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Model/GrouperGroup.php
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,13 @@ public function getSearchedGroups(array $conditions)
$searchCriteria = $conditions['searchcriteria'];

foreach ($pageResults as $result) {
$match = preg_grep("/$searchCriteria/i", $result);
$compare = $result;
unset($compare['extension']);
unset($compare['uuid']);
unset($compare['enabled']);
unset($compare['typeOfGroup']);
unset($compare['idIndex']);
$match = preg_grep("/$searchCriteria/i", $compare);
if (!empty($match)) {
$returnResults[] = $result;
}
Expand Down

0 comments on commit a5d4048

Please sign in to comment.