From 69953588fa20efae3d33799508ac5658663c08ec Mon Sep 17 00:00:00 2001 From: yashodha Date: Thu, 9 Feb 2017 09:31:02 +0530 Subject: [PATCH] CRM-19950 : Wrong param passed to checkPermission function --- CRM/Contact/BAO/Group.php | 2 +- CRM/Core/BAO/UFGroup.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CRM/Contact/BAO/Group.php b/CRM/Contact/BAO/Group.php index fe781a5cc3..aab9bc9cd9 100644 --- a/CRM/Contact/BAO/Group.php +++ b/CRM/Contact/BAO/Group.php @@ -900,7 +900,7 @@ class CRM_Contact_BAO_Group extends CRM_Contact_DAO_Group { $visibility = CRM_Core_SelectValues::ufVisibility(); while ($object->fetch()) { - $permission = CRM_Contact_BAO_Group::checkPermission($object->id, $object->title); + $permission = CRM_Contact_BAO_Group::checkPermission($object->id, TRUE); //@todo CRM-12209 introduced an ACL check in the whereClause function // it may be that this checking is now obsolete - or that what remains // should be removed to the whereClause (which is also accessed by getCount) diff --git a/CRM/Core/BAO/UFGroup.php b/CRM/Core/BAO/UFGroup.php index de3cb70ce0..392905e8b8 100644 --- a/CRM/Core/BAO/UFGroup.php +++ b/CRM/Core/BAO/UFGroup.php @@ -1063,7 +1063,7 @@ class CRM_Core_BAO_UFGroup extends CRM_Core_DAO_UFGroup { foreach ($groups as $g) { // CRM-8362: User and User Admin visibility groups should be included in display if user has // VIEW permission on that group - $groupPerm = CRM_Contact_BAO_Group::checkPermission($g['group_id'], $g['title']); + $groupPerm = CRM_Contact_BAO_Group::checkPermission($g['group_id'], TRUE); if ($g['visibility'] != 'User and User Admin Only' || CRM_Utils_Array::key(CRM_Core_Permission::VIEW, $groupPerm) -- 2.25.1