support the address-data report entry
authorchrysn <chrysn@fsfe.org>
Thu, 3 Apr 2014 13:11:11 +0000 (15:11 +0200)
committerJelmer Vernooij <jelmer@jelmer.uk>
Sat, 9 Apr 2016 18:42:17 +0000 (18:42 +0000)
rfc6352 defines CARDDAV:address-data as a way to include the body of a
card in a report result. it also specifies that the client can restrict
the list of properties that should be returned about the resource in the
CARDDAV:address-data line in the report request, but implementing the
simple case (as was done with calendar-data before) is sufficient to
make the davdroid client happy.

calypso/xmlutils.py

index 127076c79f42ea3daf80b4337272f722f5f9c39b..af2ad86a6768ae2a4cd4ffff824b350ede4ff655 100644 (file)
@@ -387,6 +387,8 @@ def report(path, xml_request, collection):
                     element.text = item.etag
                 elif tag == _tag("C", "calendar-data"):
                     element.text = item.text
+                elif tag == _tag("A", "address-data"):
+                    element.text = item.text
                 prop.append(element)
 
             status = ET.Element(_tag("D", "status"))