summaryrefslogtreecommitdiff
path: root/alot/db
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2021-02-07 10:01:43 +0100
committerAnton Khirnov <anton@khirnov.net>2021-02-07 10:01:43 +0100
commit0da20384169847aebe2ca4aa70557bf9cb726c48 (patch)
treefb459f493bcb1d2462bf361e14f83d570fa79373 /alot/db
parent2f112621568fa7f8e90e59176dea905603986609 (diff)
commands/search: refactor applying the tag command
Apply toggle as a single db write rather than two.
Diffstat (limited to 'alot/db')
-rw-r--r--alot/db/thread.py23
1 files changed, 0 insertions, 23 deletions
diff --git a/alot/db/thread.py b/alot/db/thread.py
index 65e74a35..13ddabda 100644
--- a/alot/db/thread.py
+++ b/alot/db/thread.py
@@ -142,29 +142,6 @@ class Thread:
tags = tags.intersection(set(m.get_tags()))
return tags
- def tags_add(self, tags):
- """
- Asynchronously add `tags` to all messages in this thread
-
- :param tags: a set of tags to be added
- :type tags: set of str
- """
-
- fut = self._dbman.tags_add('thread:' + self.id, tags)
- fut.add_done_callback(lambda fut: self.refresh())
- return fut
-
- def tags_remove(self, tags):
- """
- Asynchronously remove `tags` from all messages in this thread
- :param tags: a set of tags to be added
- :type tags: set of str
- """
- fut = self._dbman.tags_remove('thread:' + self.id, tags)
- fut.add_done_callback(lambda fut: self.refresh())
- return fut
-
-
def get_authors(self):
"""
returns a list of authors (name, addr) of the messages.