From 5b307826d9c25d99992de82b40d0c1a209660cd5 Mon Sep 17 00:00:00 2001 From: Adam Taylor Date: Mon, 20 May 2024 21:17:41 -0600 Subject: [PATCH] WIP --- src/friendlytagloader/templatetags/friendly_loader.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/friendlytagloader/templatetags/friendly_loader.py b/src/friendlytagloader/templatetags/friendly_loader.py index 3fd6946..fe044aa 100644 --- a/src/friendlytagloader/templatetags/friendly_loader.py +++ b/src/friendlytagloader/templatetags/friendly_loader.py @@ -89,7 +89,7 @@ def do_if_has_tag(parser, token, negate=False): end_tag = 'end%s' % bits[0] has_tag = all([tag in parser.tags for tag in bits[1:]]) has_tag = (not negate and has_tag) or (negate and not has_tag) - nodelist_true = nodelist_false = CommentNode() + nodelist_true = nodelist_false = [CommentNode()] if has_tag: nodelist_true = parser.parse(('else', end_tag)) token = parser.next_token()