Created
October 17, 2013 13:08
-
-
Save andreagrandi/7024561 to your computer and use it in GitHub Desktop.
Class used to disable CSRF check. Include this class in MIDDLEWARE_CLASSES in settings.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class DisableCSRF(object): | |
def process_request(self, request): | |
setattr(request, '_dont_enforce_csrf_checks', True) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment