mirror of
https://github.com/Xevion/tcp-chat.git
synced 2025-12-06 11:16:39 -06:00
reorganizing oserver.py into proper folder, creating client class for organization and clarity
This commit is contained in:
@@ -32,3 +32,8 @@ def prepare_server_message(nickname: str, message: str, color: str, msgtime: int
|
||||
'time': msgtime or int(time.time())
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
def prepare_request(request: str) -> bytes:
|
||||
"""Helper function for creating a request message."""
|
||||
return prepare_json({'type': constants.Types.REQUEST, 'request': request})
|
||||
|
||||
Reference in New Issue
Block a user