new version of alot requires the account set

This commit is contained in:
Felix Van der Jeugt 2020-03-04 12:07:33 +01:00
parent dde079d34f
commit ad46ab6212
No known key found for this signature in database
GPG key ID: 58B209295023754D
2 changed files with 6 additions and 4 deletions

View file

@ -8,6 +8,7 @@ async def delay(ui, days):
async def spam(ui):
from alot.buffers import EnvelopeBuffer
from alot.db.envelope import Envelope
from alot.settings.const import settings
message = ui.current_buffer.get_selected_message()
message.add_tags(['spam'])
message.remove_tags(['unread'])
@ -18,6 +19,7 @@ async def spam(ui):
Subject=['spam'],
References=['<' + message.get_message_id() + '>']),
bodytext='spam',
tags=['spam'])
tags=['spam'],
account=settings.account_matching_address('felix.vanderjeugt@ugent.be'))
envelope.attach(message.get_filename())
ui.buffer_open(EnvelopeBuffer(ui, envelope))