1. Christopher Young
  2. django-room-scheduler

Commits

Christopher Young  committed 829b0d7

Fixing unreserve permissions

  • Participants
  • Parent commits 13a7018
  • Branches default

Comments (0)

Files changed (1)

File timeslots/models.py

View file
         if requester.is_superuser:
             return (True, '')i
         #shameful hack - remove
-        if requester.email != renter.email:
+        if requester.pk != renter.pk:
             return (False, "You cannot unreserve someone else's timeslot")
         if self.start_time_and_date < datetime.datetime.now():
             return (False, '')