diff options
author | Patrick Totzke <patricktotzke@gmail.com> | 2012-02-08 21:29:27 +0000 |
---|---|---|
committer | Patrick Totzke <patricktotzke@gmail.com> | 2012-02-08 22:14:38 +0000 |
commit | 2c94f049ea2d8f5b0a9b9c3a98d9e84360e01beb (patch) | |
tree | 00eea6cf400bc48a43bee53d3d94a9447e8f4f74 /alot/account.py | |
parent | 44b85b2a1b9d35403f9c6cc6840d9c8f2547f31d (diff) |
DBManager.add_message rewrite
only queue requested changes to internal
write queue, let the lifting be done later in `flush`.
This refactors add_message to also accept a `tags` parameter,
a list of tagstrings that the message gets tagged with initially.
The new interface is used in account
Diffstat (limited to 'alot/account.py')
-rw-r--r-- | alot/account.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/alot/account.py b/alot/account.py index 1a405df9..abd44db5 100644 --- a/alot/account.py +++ b/alot/account.py @@ -134,8 +134,7 @@ class Account(object): # I wish the mailbox module were more helpful... path = glob.glob(os.path.join(mbx._path, '*', message_id + '*'))[0] - message = self.dbman.add_message(path) - message.add_tags(tags) + message = self.dbman.add_message(path, tags) self.dbman.flush() return True |