forked from lavina/lavina
add sender to ping response
This commit is contained in:
parent
1895084ded
commit
51d7278617
|
@ -203,7 +203,7 @@ pub enum JoinResult {
|
|||
}
|
||||
|
||||
/// Player update event type which is sent to a player actor and from there to a connection handler.
|
||||
#[derive(Clone)]
|
||||
#[derive(Clone, Debug)]
|
||||
pub enum Updates {
|
||||
RoomTopicChanged {
|
||||
room_id: RoomId,
|
||||
|
|
|
@ -273,6 +273,7 @@ async fn handle_update(
|
|||
rooms: &RoomRegistry,
|
||||
update: Updates,
|
||||
) -> Result<()> {
|
||||
log::debug!("Sending irc message to player {player_id:?} on update {update:?}");
|
||||
match update {
|
||||
Updates::RoomJoined {
|
||||
new_member_id,
|
||||
|
@ -378,7 +379,7 @@ async fn handle_incoming_message(
|
|||
ClientMessage::Ping { token } => {
|
||||
ServerMessage {
|
||||
tags: vec![],
|
||||
sender: None,
|
||||
sender: Some(config.server_name.clone()),
|
||||
body: ServerMessageBody::Pong {
|
||||
from: config.server_name.clone(),
|
||||
token,
|
||||
|
|
Loading…
Reference in New Issue