From 42d395aa7e768122169b5551966101e663b6709e Mon Sep 17 00:00:00 2001 From: Sanj Date: Wed, 16 Nov 2011 18:51:15 +0530 Subject: [PATCH] make_li dont li if blank --- printaform/formaprint/templatetags/random.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/printaform/formaprint/templatetags/random.py b/printaform/formaprint/templatetags/random.py index a17c2df..aa31b78 100755 --- a/printaform/formaprint/templatetags/random.py +++ b/printaform/formaprint/templatetags/random.py @@ -6,7 +6,8 @@ def make_li(value): lines = value.split("\n") ret = '' for l in lines: - ret += "
  • %s
  • " % l + if l.strip() != '': + ret += "
  • %s
  • " % l return mark_safe(ret) register.filter("make_li", make_li)