Changed the signature of the login hijack signal.
authordeyk <deyk@crossway.org>
Thu, 12 Apr 2012 17:50:57 +0000 (10:50 -0700)
committerdeyk <deyk@crossway.org>
Thu, 12 Apr 2012 17:50:57 +0000 (10:50 -0700)
cas_provider/signals.py
cas_provider/views.py

index aa939a4..5a16f9f 100644 (file)
@@ -6,4 +6,4 @@ from django import dispatch
 
 on_cas_collect_histories = dispatch.Signal(providing_args=["for_email"])
 
 
 on_cas_collect_histories = dispatch.Signal(providing_args=["for_email"])
 
-on_cas_login = dispatch.Signal(providing_args=["request", "kwargs"])
+on_cas_login = dispatch.Signal(providing_args=["request"])
index 4121a11..5ba62e6 100644 (file)
@@ -95,8 +95,7 @@ def login(request, template_name='cas/login.html', success_redirect='/account/',
             errors.append('This account is disabled.')
         else:
             # Send the on_cas_login signal. If we get an HttpResponse, return that.
             errors.append('This account is disabled.')
         else:
             # Send the on_cas_login signal. If we get an HttpResponse, return that.
-            for receiver, response in signals.on_cas_login(sender=login, request=request,
-                                                           kwargs=kwargs):
+            for receiver, response in signals.on_cas_login.send(sender=login, request=request, **kwargs):
                 if isinstance(response, HttpResponse):
                     return response
             
                 if isinstance(response, HttpResponse):
                     return response