Commit 3379a870 authored by Sofia Papagiannaki's avatar Sofia Papagiannaki
Browse files

fix local login from cms

parent 5f0086d2
......@@ -37,6 +37,7 @@ from django.template import RequestContext
from django.contrib.auth import authenticate
from django.contrib import messages
from django.utils.translation import ugettext as _
from django.views.decorators.csrf import csrf_exempt
from astakos.im.util import prepare_response
from astakos.im.views import requires_anonymous
......@@ -49,6 +50,7 @@ from ratelimit.decorators import ratelimit
retries = RATELIMIT_RETRIES_ALLOWED-1
rate = str(retries)+'/m'
@csrf_exempt
@requires_anonymous
@ratelimit(field='username', method='POST', rate=rate)
def login(request, on_failure='im/login.html'):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment