Author: lukeplant Date: 2010-02-27 15:08:30 -0600 (Sat, 27 Feb 2010) New Revision: 12619
Modified: django/trunk/django/contrib/admin/sites.py Log: Fixed #12933 - AdminSite.admin_view disables @csrf_view_exempt Thanks to philomat for report and patch. Modified: django/trunk/django/contrib/admin/sites.py =================================================================== --- django/trunk/django/contrib/admin/sites.py 2010-02-27 21:00:38 UTC (rev 12618) +++ django/trunk/django/contrib/admin/sites.py 2010-02-27 21:08:30 UTC (rev 12619) @@ -196,7 +196,8 @@ inner = never_cache(inner) # We add csrf_protect here so this function can be used as a utility # function for any view, without having to repeat 'csrf_protect'. - inner = csrf_protect(inner) + if not getattr(view, 'csrf_exempt', False): + inner = csrf_protect(inner) return update_wrapper(inner, view) def get_urls(self): -- You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-upda...@googlegroups.com. To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-updates?hl=en.