diff options
-rw-r--r-- | app/templates/base.html | 6 | ||||
-rw-r--r-- | app/views/__init__.py | 4 |
2 files changed, 10 insertions, 0 deletions
diff --git a/app/templates/base.html b/app/templates/base.html index 05b12bc..e39097c 100644 --- a/app/templates/base.html +++ b/app/templates/base.html @@ -135,6 +135,12 @@ <a href="{{ url_for('flatpage', path='policy_and_guidance') }}">{{ _("Policy and Guidance") }}</a> | <a href="{{ url_for('flatpage', path='help/reporting') }}">{{ _("Report / DMCA") }}</a> | <a href="{{ url_for('user_list_page') }}">{{ _("User List") }}</a> + + {% if debug %} + <p style="color: red"> + DEBUG MODE ENABLED + </p> + {% endif %} </footer> <script src="/static/jquery.min.js"></script> diff --git a/app/views/__init__.py b/app/views/__init__.py index c99ca03..3abb7ee 100644 --- a/app/views/__init__.py +++ b/app/views/__init__.py @@ -25,6 +25,10 @@ from urllib.parse import urlparse from sqlalchemy.sql.expression import func cache = SimpleCache() +@app.context_processor +def inject_debug(): + return dict(debug=app.debug) + @app.template_filter() def throw(err): raise Exception(err) |