Skip to content

Commit

Permalink
Update percent formatter.
Browse files Browse the repository at this point in the history
  • Loading branch information
adamghill committed Jun 30, 2024
1 parent 47de82e commit eb65fd7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion django_unicorn/templatetags/unicorn.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ def unicorn(parser, token):
contents = token.split_contents()

if len(contents) < MINIMUM_ARGUMENT_COUNT:
raise template.TemplateSyntaxError("%r tag requires at least a single argument" % token.contents.split()[0])
first_arg = token.contents.split()[0]
raise template.TemplateSyntaxError(f"{first_arg} tag requires at least a single argument")

component_name = parser.compile_filter(contents[1])

Expand Down

0 comments on commit eb65fd7

Please sign in to comment.