[Tickets #12516] CardDav attribute value delete

noreply at bugs.horde.org noreply at bugs.horde.org
Wed Jul 31 09:55:31 UTC 2013


DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.

Ticket URL: http://bugs.horde.org/ticket/12516
------------------------------------------------------------------------------
  Ticket             | 12516
  Created By         | carlos.velasco at nimastelecom.com
  Summary            | CardDav attribute value delete
  Queue              | Turba
  Version            | Git master
  Type               | Bug
  State              | Unconfirmed
  Priority           | 2. Medium
  Milestone          |
  Patch              |
  Owners             |
------------------------------------------------------------------------------


carlos.velasco at nimastelecom.com (2013-07-31 09:55) wrote:

Testing SOGo for thunderbird (CardDav client) I realized that if you  
try to delete a contact's attribute in Horde, you can't.

Example, if you have a contact with:
object_firstname: foo
object_homephone: 5551111
object_workphone: 5552222

And we delete the workphone.

SOGo connector sends a PUT without the workphone (deleted), like this:
BEGIN:VCARD
VERSION:3.0
PRODID:-//Inverse inc.//SOGo Connector 1.0//EN
UID:20130730134707.8L8VpqSPT9rDS3Bqcglzyg1 at xxxxxxxxx
N:;foo
FN:foo
TEL;TYPE=home:5551111
X-MOZILLA-HTML:FALSE
END:VCARD

Horde ignores the missing workphone and does not delete it in the database.

Modifications to any attribute, including workphone works fine, but  
you can't delete any attribute (identity property types).

I think the code relevant for this is in turba/lib/Application.php  
line 791, where values are set in the contacts, but only for the ones  
passed in the PUT vcard:
===
foreach ($contact as $attribute => $value) {
     if ($attribute != '__key') {
         $existing_contact->setValue($attribute, $value);
     }
===

Question, is this behaviour intentional?
I suppose you could delete an attribute value setting the field blank:
TEL;TYPE=work:

But I am not really sure this should be the right method, if you PUT a  
full contact I think it should be all replaced.






More information about the bugs mailing list