aboutsummaryrefslogtreecommitdiffstats
path: root/debug_toolbar/panels/template/panel.py
diff options
context:
space:
mode:
authorAymeric Augustin2013-11-16 09:58:32 +0100
committerAymeric Augustin2013-11-16 10:10:09 +0100
commit3d639ab35c2ca038d738253b93b593a755756cff (patch)
treea7d5082b065c5ab11fcfacddfc71465d90f90993 /debug_toolbar/panels/template/panel.py
parent71a2c1237de8ed759c3ba415c8bfd91b62adf193 (diff)
downloaddjango-debug-toolbar-3d639ab35c2ca038d738253b93b593a755756cff.tar.bz2
Avoid providing the same information through multiple paths.
Diffstat (limited to 'debug_toolbar/panels/template/panel.py')
-rw-r--r--debug_toolbar/panels/template/panel.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/debug_toolbar/panels/template/panel.py b/debug_toolbar/panels/template/panel.py
index 7c4b06a..b877a53 100644
--- a/debug_toolbar/panels/template/panel.py
+++ b/debug_toolbar/panels/template/panel.py
@@ -16,7 +16,6 @@ from django.utils.translation import ugettext_lazy as _
from debug_toolbar.panels import DebugPanel
from debug_toolbar.panels.sql.tracking import recording, SQLQueryTriggered
-from debug_toolbar.utils import settings as dt_settings
# Code taken and adapted from Simon Willison and Django Snippets:
# http://www.djangosnippets.org/snippets/766/
@@ -147,7 +146,7 @@ class TemplateDebugPanel(DebugPanel):
template.origin_name = 'No origin'
info['template'] = template
# Clean up context for better readability
- if dt_settings.CONFIG['SHOW_TEMPLATE_CONTEXT']:
+ if self.toolbar.config['SHOW_TEMPLATE_CONTEXT']:
context_list = template_data.get('context', [])
info['context'] = '\n'.join(context_list)
template_context.append(info)