aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiguel Araujo Perez2011-06-09 20:58:46 +0200
committerMiguel Araujo Perez2011-06-09 20:58:46 +0200
commitab01a82b42a1e3641a79d4d14e8c96b03ba47298 (patch)
tree0a4f9aade6e11eecbcf2cc7d8514fe4a7c87107c
parent929c6be2e50b662ee8dc73f40028d832323ef610 (diff)
downloaddjango-debug-toolbar-ab01a82b42a1e3641a79d4d14e8c96b03ba47298.tar.bz2
Fixes TemplateDebugPanel iterating over an unknown template without origin or name
-rw-r--r--debug_toolbar/panels/template.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/debug_toolbar/panels/template.py b/debug_toolbar/panels/template.py
index 44b8b3e..1d543f9 100644
--- a/debug_toolbar/panels/template.py
+++ b/debug_toolbar/panels/template.py
@@ -78,6 +78,8 @@ class TemplateDebugPanel(DebugPanel):
# Skip templates that we are generating through the debug toolbar.
if template.name and template.name.startswith('debug_toolbar/'):
continue
+ if template.name == "<Unknown Template>":
+ continue
if template.origin and template.origin.name:
template.origin_name = template.origin.name
else: