summaryrefslogtreecommitdiff
path: root/alot
diff options
context:
space:
mode:
authorPatrick Totzke <patricktotzke@gmail.com>2011-12-14 20:45:52 +0000
committerPatrick Totzke <patricktotzke@gmail.com>2011-12-14 21:40:59 +0000
commitb5747bfc7c42fd861565f4e6508c4d5b4c50b22d (patch)
treefd4c1082c3b9f8442b99591fa81126428d1a61cf /alot
parent630d11a69efeab53610770b9f7379071db0caef1 (diff)
fix: remove decode_header call from ComposeCommand
envelope.headers' values are already decoded! fixes issue #155
Diffstat (limited to 'alot')
-rw-r--r--alot/commands/globals.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/alot/commands/globals.py b/alot/commands/globals.py
index 826601a4..b7e55598 100644
--- a/alot/commands/globals.py
+++ b/alot/commands/globals.py
@@ -20,7 +20,6 @@ from alot import helper
from alot.db import DatabaseLockedError
from alot.completion import ContactsCompleter
from alot.completion import AccountCompleter
-from alot.message import decode_header
from alot.message import Envelope
from alot import commands
@@ -527,7 +526,7 @@ class ComposeCommand(Command):
# get missing To header
if 'To' not in self.envelope.headers:
- sender = decode_header(self.envelope.headers.get('From'))
+ sender = self.envelope.headers.get('From')
name, addr = email.Utils.parseaddr(sender)
a = ui.accountman.get_account_by_address(addr)
@@ -543,6 +542,7 @@ class ComposeCommand(Command):
ui.notify('canceled')
return
self.envelope.headers['To'] = to
+
if settings.config.getboolean('general', 'ask_subject') and \
not 'Subject' in self.envelope.headers:
subject = yield ui.prompt(prefix='Subject>')