Skip to content
Browse files

Make sure new_notification is actually in POST before we try to use it

  • Loading branch information...
1 parent 71e79bb commit 24ff36eb283a1f1e0d6314d230138d4206aed7b4 @mhagander mhagander committed
Showing with 1 addition and 1 deletion.
  1. +1 −1 pgweb/util/
2 pgweb/util/
@@ -59,7 +59,7 @@ def save_model(self, request, obj, form, change):
if change and self.model.send_notification:
# We only do processing if something changed, not when adding
# a new object.
- if request.POST['new_notification']:
+ if request.POST.has_key('new_notification') and request.POST['new_notification']:
# Need to send off a new notification. We'll also store
# it in the database for future reference, of course.
if not

0 comments on commit 24ff36e

Please sign in to comment.
Something went wrong with that request. Please try again.