diff --git a/CRM/Upgrade/Incremental/SmartGroups.php b/CRM/Upgrade/Incremental/SmartGroups.php index 011c75a4cdd..70c272511d9 100644 --- a/CRM/Upgrade/Incremental/SmartGroups.php +++ b/CRM/Upgrade/Incremental/SmartGroups.php @@ -232,12 +232,11 @@ public function renameFields($pairs) { * @return mixed */ protected function getSearchesWithField($field) { - $savedSearches = civicrm_api3('SavedSearch', 'get', [ + return civicrm_api3('SavedSearch', 'get', [ 'options' => ['limit' => 0], 'form_values' => ['LIKE' => "%{$field}%"], + 'return' => ['id', 'form_values'], ])['values']; - return $savedSearches; - } /**