Commits

Christopher Young committed cd5c1a1

Fixing unreserve permissions, yet again

  • Participants
  • Parent commits 829b0d7

Comments (0)

Files changed (1)

File timeslots/models.py

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