[FIX] html2plaintext: bug 1159782

bzr revid: chm@openerp.com-20130329154130-56wjtfrj41eatxl6
This commit is contained in:
Christophe Matthieu 2013-03-29 16:41:30 +01:00
parent 42e713aab2
commit 600f03b294
1 changed files with 2 additions and 0 deletions

View File

@ -185,6 +185,8 @@ def html2plaintext(html, body_id=None, encoding='utf-8'):
url_index.append(url)
html = ustr(etree.tostring(tree, encoding=encoding))
# \r char is converted into 
, must remove it
html = html.replace('
', '')
html = html.replace('<strong>', '*').replace('</strong>', '*')
html = html.replace('<b>', '*').replace('</b>', '*')