summaryrefslogtreecommitdiff
path: root/poezio/xhtml.py
diff options
context:
space:
mode:
Diffstat (limited to 'poezio/xhtml.py')
-rw-r--r--poezio/xhtml.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/poezio/xhtml.py b/poezio/xhtml.py
index b84ce943..ef2334fb 100644
--- a/poezio/xhtml.py
+++ b/poezio/xhtml.py
@@ -396,8 +396,8 @@ class XHTMLHandler(sax.ContentHandler):
if name == 'a':
self.pop_formatting()
# do not display the link twice
- text_elements = filter(lambda x: not x.startswith('\x19'),
- self.builder[self.a_start:])
+ text_elements = [x for x in self.builder[self.a_start:]
+ if not x.startswith('\x19')]
link_text = ''.join(text_elements).strip()
if 'href' in attrs and attrs['href'] != link_text:
builder.append(' (%s)' % trim(attrs['href']))