mirror of
https://github.com/not-kennethreitz/flask-sslify.git
synced 2026-06-05 06:56:15 +00:00
Removed completely turning off redirects stuff.
This commit is contained in:
@@ -70,12 +70,6 @@ You can exlude a path that starts with given string by including a list called `
|
||||
Or by including ``SSL_SKIPS`` in your app's config.
|
||||
|
||||
|
||||
Turn-off Redirects Completely
|
||||
------------------------------
|
||||
Flask-SSLify won't run if ``DEBUG`` is ``True``, but you can also turn-off redirects completely by setting
|
||||
``SSL_NO_REDIRECTS`` in your app's config which might be useful for things like testing, etc.
|
||||
|
||||
|
||||
Install
|
||||
-------
|
||||
|
||||
|
||||
+1
-1
@@ -9,7 +9,7 @@ class SSLify(object):
|
||||
"""Secures your Flask App."""
|
||||
|
||||
def __init__(self, app, age=YEAR_IN_SECS, subdomains=False, permanent=False, skips=None):
|
||||
if app is not None and not app.config.get('SSL_NO_REDIRECTS'):
|
||||
if app is not None:
|
||||
self.app = app
|
||||
self.hsts_age = age
|
||||
self.hsts_include_subdomains = subdomains or app.config.get('SSL_SUBDOMAINS')
|
||||
|
||||
Reference in New Issue
Block a user