Assume that the collection is an addressbook when "carddav" is in URL

This commit is contained in:
Guillaume Ayoub 2013-07-26 17:47:51 +02:00
parent faa331ccc3
commit 3e3f07a6de

View File

@ -396,7 +396,7 @@ class Collection(object):
try: try:
tag = open(self.path).readlines()[0][6:].rstrip() tag = open(self.path).readlines()[0][6:].rstrip()
except IOError: except IOError:
if self.path.endswith(".vcf"): if self.path.endswith(".vcf") or "carddav" in self.path:
props["tag"] = "VADDRESSBOOK" props["tag"] = "VADDRESSBOOK"
else: else:
props["tag"] = "VCALENDAR" props["tag"] = "VCALENDAR"