fix: print when sending websocket message for debug
This commit is contained in:
parent
f18ec348cb
commit
34e591cb00
1 changed files with 2 additions and 0 deletions
|
|
@ -22,6 +22,8 @@ pub fn connect() -> Result<WebSocket<MaybeTlsStream<TcpStream>>, tungstenite::Er
|
|||
pub fn send(socket: &mut WebSocket<MaybeTlsStream<TcpStream>>, cpu: u8, ram: u8) {
|
||||
let message = format!("{{ \"cpu\": {}, \"ram\": {} }}", cpu, ram);
|
||||
|
||||
println!("Sending to WebSocket: {}", message);
|
||||
|
||||
socket
|
||||
.send(Message::Text(message))
|
||||
.unwrap();
|
||||
|
|
|
|||
Loading…
Reference in a new issue