improvements

Signed-off-by: Jess Frazelle <github@jessfraz.com>
This commit is contained in:
Jess Frazelle
2023-11-28 14:16:05 -08:00
parent b6aa9ab98b
commit 6b8807feea
16 changed files with 2291 additions and 643 deletions

View File

@ -179,4 +179,8 @@ class WebSocket:
"""Receive data from the websocket."""
message = self.ws.recv()
return {{response_type}}.from_dict(json.loads(message))
def close(self):
"""Close the websocket."""
self.ws.close()
{%endif%}