From 9c40e5f3af834b89794fdc586211f4325999767c Mon Sep 17 00:00:00 2001 From: missytake Date: Tue, 20 Aug 2024 13:29:52 +0200 Subject: [PATCH] added docstring --- src/team_bot/bot.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/team_bot/bot.py b/src/team_bot/bot.py index 95a2573..ae34960 100644 --- a/src/team_bot/bot.py +++ b/src/team_bot/bot.py @@ -268,7 +268,11 @@ class RelayPlugin: return self.account.get_chat_by_id(mapping[1]) return None - def offboard(self, ex_admin): + def offboard(self, ex_admin: deltachat.Contact) -> None: + """Remove a former crew member from all relay groups they are part of. + + :param ex_admin: a contact which just got removed from the crew. + """ for mapping in self.kvstore.get("relays"): relay_group = self.account.get_chat_by_id(mapping[1]) if ex_admin in relay_group.get_contacts():