From 309fb25e9b089618c37f1a741fa6009cce54ac9e Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sat, 30 Jan 2021 16:33:56 +0100 Subject: db/attachment: simplify the Attachment class Make it a plain container around raw data and a few bits of metadata, rather than around a whole MIME part. --- alot/widgets/globals.py | 3 --- 1 file changed, 3 deletions(-) (limited to 'alot/widgets') diff --git a/alot/widgets/globals.py b/alot/widgets/globals.py index 8b9b3065..7f2a9dcd 100644 --- a/alot/widgets/globals.py +++ b/alot/widgets/globals.py @@ -10,7 +10,6 @@ import operator import urwid from ..settings.const import settings -from ..db.attachment import Attachment from ..errors import CompletionError @@ -22,8 +21,6 @@ class AttachmentWidget(urwid.WidgetWrap): def __init__(self, attachment, selectable=True): self._selectable = selectable self.attachment = attachment - if not isinstance(attachment, Attachment): - self.attachment = Attachment(self.attachment) att = settings.get_theming_attribute('thread', 'attachment') focus_att = settings.get_theming_attribute('thread', 'attachment_focus') -- cgit v1.2.3