summaryrefslogtreecommitdiff
path: root/alot/commands/envelope.py
diff options
context:
space:
mode:
Diffstat (limited to 'alot/commands/envelope.py')
-rw-r--r--alot/commands/envelope.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/alot/commands/envelope.py b/alot/commands/envelope.py
index f7337968..4b5a1fcc 100644
--- a/alot/commands/envelope.py
+++ b/alot/commands/envelope.py
@@ -81,7 +81,7 @@ class UnattachCommand(Command):
if self.hint is not None:
for a in envelope.attachments:
- if self.hint in a.get_filename():
+ if a.filename and self.hint in a.filename():
envelope.attachments.remove(a)
else:
envelope.attachments = []