diff options
author | Trygve Aaberge <trygveaa@gmail.com> | 2023-01-29 21:15:15 +0100 |
---|---|---|
committer | Trygve Aaberge <trygveaa@gmail.com> | 2024-02-18 11:32:53 +0100 |
commit | c643c84a253b3e98f5e0a1fc19855e948c84fc99 (patch) | |
tree | 9e593d86833a7aa3a831cdf74eb2e4e152214d32 /slack/slack_workspace.py | |
parent | a91e003fcdb63e80172b2c001597f4042179d04e (diff) | |
download | wee-slack-c643c84a253b3e98f5e0a1fc19855e948c84fc99.tar.gz |
Add command /slack disconnect
Diffstat (limited to 'slack/slack_workspace.py')
-rw-r--r-- | slack/slack_workspace.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/slack/slack_workspace.py b/slack/slack_workspace.py index ac2b1e7..0e16920 100644 --- a/slack/slack_workspace.py +++ b/slack/slack_workspace.py @@ -249,3 +249,8 @@ class SlackWorkspace: def ws_recv(self, data: object): print(f"received: {data}") + + def disconnect(self): + self.is_connected = False + weechat.unhook(self.hook) + self.ws.close() |