mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
fmt
This commit is contained in:
parent
0bc6b64002
commit
5c19ddb06c
@ -299,18 +299,19 @@ fn handle_players(server: &mut Server, entity: EcsEntity, _args: String, _action
|
||||
if count > 0 {
|
||||
let mut player_iter = players.join();
|
||||
let first = player_iter.next().unwrap().alias.to_owned();
|
||||
let player_list = player_iter
|
||||
.fold(first, |s, p| {
|
||||
s += ",\n";
|
||||
s += &p.alias;
|
||||
s
|
||||
});
|
||||
let player_list = player_iter.fold(first, |s, p| {
|
||||
s += ",\n";
|
||||
s += &p.alias;
|
||||
s
|
||||
});
|
||||
|
||||
server
|
||||
.clients
|
||||
.notify(entity, ServerMsg::Chat(header_message + &player_list));
|
||||
} else {
|
||||
server.clients.notify(entity, ServerMsg::Chat(header_message));
|
||||
server
|
||||
.clients
|
||||
.notify(entity, ServerMsg::Chat(header_message));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user