Skip to content
Snippets Groups Projects
Commit b9409a10 authored by Seamus Lee's avatar Seamus Lee
Browse files

Fix issue with building smart groups when is empty

parent 568689a7
Branches
Tags
No related merge requests found
......@@ -489,7 +489,9 @@ WHERE id IN ( $groupIDs )
$tempTable = $groupContactsTempTable->getName();
$groupContactsTempTable->createWithColumns('contact_id int, group_id int, UNIQUE UI_contact_group (contact_id,group_id)');
$contactQueries[] = $sql;
if (!empty($sql)) {
$contactQueries[] = $sql;
}
// lets also store the records that are explicitly added to the group
// this allows us to skip the group contact LEFT JOIN
$contactQueries[] =
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment