From c6fd2111198333b985115a3485b5e59d8f076999 Mon Sep 17 00:00:00 2001 From: Pratik Joshi Date: Tue, 3 Dec 2013 14:22:19 +0530 Subject: [PATCH] CRM-13861 : instead of strpos check on 'title' of group lets do a check on profile's group type so that no translation specific issue araise --- CRM/Contact/BAO/Relationship.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CRM/Contact/BAO/Relationship.php b/CRM/Contact/BAO/Relationship.php index c4c1f11ee8..4f40d5015a 100644 --- a/CRM/Contact/BAO/Relationship.php +++ b/CRM/Contact/BAO/Relationship.php @@ -1510,7 +1510,8 @@ AND cc.sort_name LIKE '%$name%'"; } else { $contactTypes = array(); foreach ($contactProfiles as $key => $value) { - if (strpos($value, $leftType) !== FALSE) { + $groupTypes = CRM_Core_BAO_UFGroup::profileGroups($key); + if (in_array($leftType, $groupTypes)) { $contactTypes = array($key => $value); } } -- 2.25.1