mirror of
https://github.com/MeexReay/sRAC.git
synced 2025-05-06 05:08:02 +03:00
bring formatting from bRAC
This commit is contained in:
parent
472ff20858
commit
7834e4ccfd
948
Cargo.lock
generated
948
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@ -5,3 +5,4 @@ edition = "2024"
|
||||
|
||||
[dependencies]
|
||||
chrono = "0.4.40"
|
||||
bRAC = { git = "https://github.com/MeexReay/bRAC.git" }
|
@ -47,8 +47,10 @@ fn accept_stream(mut stream: TcpStream, messages: Arc<RwLock<Vec<u8>>>) -> Resul
|
||||
msg.push(b' ');
|
||||
msg.append(&mut buf);
|
||||
|
||||
println!("{}", String::from_utf8_lossy(&msg));
|
||||
|
||||
if let Some(msg) = bRAC::chat::format_message(true, String::from_utf8_lossy(&msg).to_string()) {
|
||||
println!("{}", msg);
|
||||
}
|
||||
|
||||
msg.push(b'\n');
|
||||
|
||||
messages.write().unwrap().append(&mut msg.clone());
|
||||
|
Loading…
Reference in New Issue
Block a user