From d2b6b6d533a8a4be088144b6d0df0dc74713d9c0 Mon Sep 17 00:00:00 2001 From: Roberto Rosario Date: Wed, 3 Oct 2012 01:19:48 -0400 Subject: [PATCH] Update the Div widget to use
 tags instead of 
to conserve spacing --- apps/common/widgets.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/common/widgets.py b/apps/common/widgets.py index c2f7906c56..bb0beb397a 100644 --- a/apps/common/widgets.py +++ b/apps/common/widgets.py @@ -88,12 +88,12 @@ class TextAreaDiv(forms.widgets.Widget): def render(self, name, value, attrs=None): if value is None: - value = '' - final_attrs = self.build_attrs(attrs, name=name) - result = mark_safe(u'%s
' % (flatatt(final_attrs), - conditional_escape(force_unicode(value)))) + value = u'' - return mark_safe(result.replace('\n', '
')) + flat_attrs = flatatt(self.build_attrs(attrs, name=name)) + content = conditional_escape(force_unicode(value)) + result = u'%s
' % (flat_attrs, content) + return mark_safe(result) # From: http://www.peterbe.com/plog/emailinput-html5-django