def linebreaksbr(value, autoescape=None):
 if (autoescape and (not isinstance(value, SafeData))):
  from google.appengine._internal.django.utils.html import escape
  value = escape(value)
 return mark_safe(value.replace('\n', '<br />'))

def linebreaksbr ( value , autoescape = None ) : if ( autoescape and ( not isinstance ( value , SafeData ) ) ) : from google . appengine . _internal . django . utils . html import escape value = escape ( value ) return mark_safe ( value . replace ( '\n' , '<br />' ) )
converts all newlines in a piece of plain text to html line breaks .