chore: use to_owned instead of to_string

This commit is contained in:
MultisampledNight 2024-01-21 21:00:36 +01:00
parent 1df57eba6b
commit 98f4a6cdeb
No known key found for this signature in database
GPG key ID: C81EF9B053977241

View file

@ -47,7 +47,7 @@ impl Configs {
{
Some("ron") => Ok(serde_json::from_str(&fs::read_to_string(p)?)?),
Some("json") => Ok(ron::from_str(&fs::read_to_string(p)?)?),
e => Err(Config::UnknownExtension(e.map(str::to_string))),
e => Err(Config::UnknownExtension(e.map(str::to_owned))),
}
}
}