Skip to content

Commit 8ac0bb5

Browse files
committed
Remove unnecessary guard
All dicts in a context have an .items() method. The Context class is a subclass of dict.
1 parent 58f374a commit 8ac0bb5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

debug_toolbar/panels/templates/panel.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ def _store_template_info(self, sender, **kwargs):
9393

9494
context_list = []
9595
for context_layer in context.dicts:
96-
if hasattr(context_layer, "items") and context_layer:
96+
if context_layer:
9797
# Refs GitHub issue #910
9898
# If we can find this layer in our pseudo-cache then find the
9999
# matching prettified version in the associated list.

0 commit comments

Comments
 (0)