1.1 --- a/imiptools/handlers/resource.py Sat Jan 31 22:34:12 2015 +0100
1.2 +++ b/imiptools/handlers/resource.py Sun Feb 01 01:59:37 2015 +0100
1.3 @@ -19,10 +19,9 @@
1.4 this program. If not, see <http://www.gnu.org/licenses/>.
1.5 """
1.6
1.7 -from imiptools.content import Handler, format_datetime, get_address, get_uri, \
1.8 - to_part
1.9 +from imiptools.content import Handler
1.10 +from imiptools.data import get_address, get_uri, to_part
1.11 from imiptools.handlers.common import CommonFreebusy
1.12 -from vCalendar import to_node
1.13
1.14 class ResourceHandler(Handler):
1.15
1.16 @@ -44,7 +43,7 @@
1.17
1.18 # Check for event using UID.
1.19
1.20 - if not self.have_new_object(attendee, "VEVENT"):
1.21 + if not self.have_new_object(attendee):
1.22 continue
1.23
1.24 # Collect response objects produced when handling the request.
1.25 @@ -70,13 +69,13 @@
1.26
1.27 # Make a version of the request with just this attendee.
1.28
1.29 - self.details["ATTENDEE"] = [(attendee, attendee_attr)]
1.30 + self.obj["ATTENDEE"] = [(attendee, attendee_attr)]
1.31
1.32 # Update the DTSTAMP.
1.33
1.34 self.update_dtstamp()
1.35
1.36 - event = to_node({"VEVENT" : [(self.details, {})]})
1.37 + event = self.obj.to_node()
1.38 self.store.set_event(attendee, self.uid, event)
1.39
1.40 # Only update free/busy details if the event is scheduled.