Not sending to sender
This commit is contained in:
@@ -106,8 +106,6 @@ impl Server {
|
|||||||
|
|
||||||
if let Err(e) = read_loop(&s, public_key, &client).await {
|
if let Err(e) = read_loop(&s, public_key, &client).await {
|
||||||
eprintln!("Failed to handle client: {e}");
|
eprintln!("Failed to handle client: {e}");
|
||||||
} else {
|
|
||||||
println!("Client connection closed")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
let mut clients_meta = s.clients.lock().await;
|
let mut clients_meta = s.clients.lock().await;
|
||||||
|
|||||||
@@ -121,6 +121,10 @@ impl Server {
|
|||||||
voice.last_speaking_sent = now;
|
voice.last_speaking_sent = now;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if *sender == user.public_key {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
let _ = self.udp_send_to(&voice.addr, payload).await;
|
let _ = self.udp_send_to(&voice.addr, payload).await;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user