Skip to content

Commit 3316b3d

Browse files
committed
Merge pull request #711 from maikhoepfel/patch-1
Don't ignore templates without an origin
2 parents 5a9bd46 + e272b51 commit 3316b3d

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

debug_toolbar/panels/templates/panel.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -201,12 +201,10 @@ def process_response(self, request, response):
201201
info = {}
202202
# Clean up some info about templates
203203
template = template_data.get('template', None)
204-
if not hasattr(template, 'origin'):
205-
continue
206-
if template.origin and template.origin.name:
204+
if hasattr(template, 'origin') and template.origin and template.origin.name:
207205
template.origin_name = template.origin.name
208206
else:
209-
template.origin_name = 'No origin'
207+
template.origin_name = _('No origin')
210208
info['template'] = template
211209
# Clean up context for better readability
212210
if self.toolbar.config['SHOW_TEMPLATE_CONTEXT']:

0 commit comments

Comments
 (0)