1 2 3 4 5 6 7 | # Create a dummy middleware class for testing, that simply removes the SSL argument
# and does nothing else.
if settings.TESTING:
class SSLRedirect:
def process_view(self, request, view_func, view_args, view_kwargs):
if SSL in view_kwargs:
del view_kwargs[SSL]
|
More like this
- SSL Redirect Middleware by zbyte64 4 years, 10 months ago
- SSL Middleware by sjzabel 6 years, 2 months ago
- Quickly check templates while sketching them out by Amr Mostafa 6 years, 1 month ago
- SSL / HTTPS Middleware for Redirection and href Rewriting by DrMeers 3 years ago
- Django model cron jobs by willhardy 4 years, 7 months ago
Comments