perf: slightly optimize Vec usage

This commit is contained in:
2025-03-10 19:58:59 -04:00
parent 2b2cf1d069
commit b2d8618bba
7 changed files with 11 additions and 11 deletions

View File

@@ -13,7 +13,7 @@ pub struct Player {
impl From<PlayerInfo> for Player {
fn from(p: PlayerInfo) -> Self {
Self {
display_name: p.display_name.map(|n| n.to_string()),
display_name: p.display_name.map(|text| text.to_string()),
gamemode: p.gamemode.to_id(),
latency: p.latency,
name: p.profile.name,