fix both ws rpc server and client due to websock breaking changes
- change recv() to recvMsg()
This commit is contained in:
parent
a1715e33ac
commit
b2417fc071
|
@ -46,7 +46,7 @@ proc processData(client: RpcWebSocketClient) {.async.} =
|
|||
let ws = client.transport
|
||||
try:
|
||||
while ws.readystate != ReadyState.Closed:
|
||||
var value = await ws.recv()
|
||||
var value = await ws.recvMsg()
|
||||
|
||||
if value.len == 0:
|
||||
# transmission ends
|
||||
|
|
|
@ -26,7 +26,7 @@ proc handleRequest(rpc: RpcWebSocketServer, request: HttpRequest) {.async.} =
|
|||
|
||||
trace "Websocket handshake completed"
|
||||
while ws.readyState != ReadyState.Closed:
|
||||
let recvData = await ws.recv()
|
||||
let recvData = await ws.recvMsg()
|
||||
trace "Client message: ", size = recvData.len, binary = ws.binary
|
||||
|
||||
if ws.readyState == ReadyState.Closed:
|
||||
|
|
Loading…
Reference in New Issue