summaryrefslogtreecommitdiff
path: root/alot/commands
diff options
context:
space:
mode:
Diffstat (limited to 'alot/commands')
-rw-r--r--alot/commands/thread.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/alot/commands/thread.py b/alot/commands/thread.py
index 1e1e3e6d..bc1cc1a4 100644
--- a/alot/commands/thread.py
+++ b/alot/commands/thread.py
@@ -711,7 +711,11 @@ class PipeCommand(Command):
if self.output_format == 'raw':
msg_data = msg.as_bytes()
elif self.output_format == 'decoded':
- headertext = '\n'.join([key + ': ' + val for key, val in msg.headers.items()])
+ # XXX HACK: filter out content-transfer-encoding, since we are writing out
+ # the decoder version
+ # should be properly handled elsewhere (where? how?)
+ headers = filter(lambda i: i[0].lower() != 'content-transfer-encoding', msg.headers.items())
+ headertext = '\n'.join([key + ': ' + val for key, val in headers])
bodytext = msg.get_body_text()
msgtext = '%s\n\n%s' % (headertext, bodytext)