[FIX] http: keep debug mode in rediction

The parameter forward_debug is used to keep the debug mode during redirection.
Previous code was setting the debug to None which is ignored by werkzeug, making
the option useless.

Closes #12107
This commit is contained in:
Martin Trigaux 2016-06-10 16:36:35 +02:00
parent 26b3501ca9
commit dd4980b0a8
No known key found for this signature in database
GPG Key ID: 7B0E288E7C0F83A7
1 changed files with 1 additions and 1 deletions

View File

@ -142,7 +142,7 @@ def local_redirect(path, query=None, keep_hash=False, forward_debug=True, code=3
if not query: if not query:
query = {} query = {}
if forward_debug and request and request.debug: if forward_debug and request and request.debug:
query['debug'] = None query['debug'] = ''
if query: if query:
url += '?' + werkzeug.url_encode(query) url += '?' + werkzeug.url_encode(query)
if keep_hash: if keep_hash: