From 2ce96a6f8dc01e2f79d553dbd92c4cfd75b2a0b8 Mon Sep 17 00:00:00 2001 From: nathan Date: Tue, 9 Nov 2021 14:33:37 -0700 Subject: [PATCH] Maybe fix SQL error from searching contacts with private + duplicates --- api/src/Contacts/Sql.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/src/Contacts/Sql.php b/api/src/Contacts/Sql.php index a6748459fc..5c3e1dba57 100644 --- a/api/src/Contacts/Sql.php +++ b/api/src/Contacts/Sql.php @@ -338,8 +338,8 @@ class Sql extends Api\Storage { if (!$this->grants[(int) $param['owner']]) return false; // we have no access to that addressbook - $filter[$this->table_name.'.contact_owner'] = $param['owner']; - $filter[$this->table_name.'.private'] = 0; + $filter[$this->table_name . '.contact_owner'] = $param['owner']; + $filter[$this->table_name . '.contact_private'] = 0; $join .= 'a2.contact_owner = ' . $this->db->quote($param['owner']) . ' AND '; $join .= 'a2.contact_private = ' . $this->db->quote($filter['private']) . ' AND '; }