Skip to content

Commit

Permalink
Merge pull request django-fiber#152 from ramonakira/dev
Browse files Browse the repository at this point in the history
Added decorator to block non-POST requests on login - Thanks Ramon!
  • Loading branch information
dbunskoek committed Feb 11, 2013
2 parents f20fada + 4ce0096 commit 07bb0d8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions fiber/admin_views.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from django.contrib.admin.views.decorators import staff_member_required
from django.views.decorators.http import require_POST
from django.contrib.auth import authenticate, login
from django.http import HttpResponse, HttpResponseRedirect
from django.utils import simplejson
Expand All @@ -7,6 +8,7 @@
from .models import Page


@require_POST
def fiber_login(request):
username = request.POST['username']
password = request.POST['password']
Expand Down

0 comments on commit 07bb0d8

Please sign in to comment.