Permalink
Browse files

Allow different users to create hunts with the same name

Signed-off-by: Stefan Hajnoczi <stefanha@gmail.com>
  • Loading branch information...
stefanha committed Aug 7, 2011
1 parent 5530a07 commit 2e66056de7f5d5e069108ab26c925a6fffc0b8bf
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/controller.py
View
@@ -52,7 +52,7 @@ class CreateHunt(webapp.RequestHandler):
@utils.logged_in
def post(self):
hunt_name = self.request.get('hunt-name')
- hunt = Hunt.all().filter('name =', hunt_name).get()
+ hunt = Hunt.all().filter('name =', hunt_name).filter('owner =', self.user).get()
if not hunt:
hunt = Hunt(name=hunt_name, owner=self.user)
hunt.put()

0 comments on commit 2e66056

Please sign in to comment.