1.1 --- a/imiptools/handlers/person.py Tue Oct 28 16:55:26 2014 +0100
1.2 +++ b/imiptools/handlers/person.py Tue Oct 28 17:59:27 2014 +0100
1.3 @@ -18,7 +18,7 @@
1.4
1.5 "Handling mechanisms specific to people."
1.6
1.7 - def _record_and_deliver(self, queue=False):
1.8 + def _record_and_deliver(self, objtype, queue=False):
1.9
1.10 oa = self.require_organiser_and_attendees()
1.11 if not oa:
1.12 @@ -30,13 +30,13 @@
1.13
1.14 for attendee, attendee_attr in attendees.items():
1.15
1.16 - if not self.have_new_object(attendee, "VEVENT"):
1.17 + if not self.have_new_object(attendee, objtype):
1.18 continue
1.19
1.20 - # Store the event and queue any request.
1.21 + # Store the object and queue any request.
1.22
1.23 self.store.set_event(attendee, self.uid, to_node(
1.24 - {"VEVENT" : [(self.details, {})]}
1.25 + {objtype : [(self.details, {})]}
1.26 ))
1.27
1.28 if queue:
1.29 @@ -100,7 +100,7 @@
1.30
1.31 "Record replies and notify the recipient."
1.32
1.33 - self._record_and_deliver(False)
1.34 + self._record_and_deliver("VEVENT", False)
1.35
1.36 # The message is now wrapped and passed on to the recipient.
1.37
1.38 @@ -110,7 +110,7 @@
1.39
1.40 "Hold requests and notify the recipient."
1.41
1.42 - self._record_and_deliver(True)
1.43 + self._record_and_deliver("VEVENT", True)
1.44
1.45 # The message is now wrapped and passed on to the recipient.
1.46
1.47 @@ -133,7 +133,7 @@
1.48
1.49 "Record replies and notify the recipient."
1.50
1.51 - self._record_and_deliver(False)
1.52 + self._record_and_deliver("VFREEBUSY", False)
1.53
1.54 # The message is now wrapped and passed on to the recipient.
1.55
1.56 @@ -266,7 +266,7 @@
1.57
1.58 "Record replies and notify the recipient."
1.59
1.60 - self._record_and_deliver(False)
1.61 + self._record_and_deliver("VTODO", False)
1.62
1.63 # The message is now wrapped and passed on to the recipient.
1.64
1.65 @@ -276,7 +276,7 @@
1.66
1.67 "Hold requests and notify the recipient."
1.68
1.69 - self._record_and_deliver(True)
1.70 + self._record_and_deliver("VTODO", True)
1.71
1.72 # The message is now wrapped and passed on to the recipient.
1.73