6.0.0-beta1
7/5/25

[#11811] saving recipients automatically causes duplicate entries
Summary saving recipients automatically causes duplicate entries
Queue Turba
Queue Version 4.0.1
Type Bug
State Not A Bug
Priority 1. Low
Owners
Requester viktor (at) szepe (dot) net
Created 12/03/2012 (4597 days ago)
Due
Updated 02/11/2013 (4527 days ago)
Assigned 01/03/2013 (4566 days ago)
Resolved 01/15/2013 (4554 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
02/11/2013 05:26:43 PM Jan Schneider Comment #8 Reply to this comment
is it OK?
  turba/lib/Api.php:682
That's the correct place, yes.
02/10/2013 12:08:16 PM viktor (at) szepe (dot) net Comment #7 Reply to this comment
is it OK?
  turba/lib/Api.php:682

        // Check if the entry already exists in the data source.
$unique_key = 'email';
if (array_key_exists($unique_key, $content)) {
         $result = $driver->search(array($unique_key => 
$content[$unique_key]));
} else {
         $result = $driver->search($content);
}
02/10/2013 11:39:43 AM viktor (at) szepe (dot) net Comment #6 Reply to this comment
That's the expected behavior. It searches all information available, 
i.e. name and address in this case. Only if all fields match, a 
contact is considered a duplicate.
Please help me modify the code locally.
I got this far:
imp/lib/Compose.php:1187
$registry->call('contacts/import', array(array('name' => $name, 
'email' => $recipient->bare_address), 'array', $abook));

Where do I find the registered 'contacts/import' funcition?
Thank you!
01/15/2013 08:58:32 PM viktor (at) szepe (dot) net Comment #5 Reply to this comment
That's the expected behavior. It searches all information available, 
i.e. name and address in this case. Only if all fields match, a 
contact is considered a duplicate.
Could you please revert the functionality (as was in H4) to match ONLY 
the email address?
01/15/2013 06:03:32 PM Jan Schneider Comment #4
State ⇒ Not A Bug
Reply to this comment
That's the expected behavior. It searches all information available, 
i.e. name and address in this case. Only if all fields match, a 
contact is considered a duplicate.
01/03/2013 11:36:11 AM viktor (at) szepe (dot) net Comment #3 Reply to this comment
This exactly the opposite from what you've written in the summary. 
So *are* you getting duplicates or *not*? And if you do, under which 
circumstances?
YES, I am getting duplicates. If there is no entry with exactly the 
same name, turba creates another entry with the same address. I 
suspect turba compares the names, not the address.
e.g.
Ételmanufaktúra, Mannatural,        info@mannatural.hu
Ételmanufaktúra,, Mannatural,,        info@mannatural.hu
Mannatural, Ételmanufaktúra        info@mannatural.hu
Mannatural,, Ételmanufaktúra,        info@mannatural.hu
01/03/2013 10:52:58 AM Jan Schneider Comment #2
State ⇒ Feedback
Reply to this comment
"Save recipients automatically to the default address book?" is on.
When I write a message to someone his/her name get into the address book
IF the there is a difference between the new name and the name 
already in the address book. Same names don't get duplicated.
This exactly the opposite from what you've written in the summary. So 
*are* you getting duplicates or *not*? And if you do, under which 
circumstances?
12/03/2012 10:26:18 PM viktor (at) szepe (dot) net Comment #1
Priority ⇒ 1. Low
Type ⇒ Bug
Summary ⇒ saving recipients automatically causes duplicate entries
Queue ⇒ Turba
Milestone ⇒
Patch ⇒ No
State ⇒ Unconfirmed
Reply to this comment
"Save recipients automatically to the default address book?" is on.
When I write a message to someone his/her name get into the address book
IF the there is a difference between the new name and the name already 
in the address book. Same names don't get duplicated.

Thank you!

Saved Queries