chore: try_load with &str instead of String

This commit is contained in:
zaaarf 2024-02-19 17:12:17 +01:00
parent 970f7ec875
commit a497b3ad5b
No known key found for this signature in database
GPG key ID: 102E445F4C3F829B

View file

@ -43,7 +43,7 @@ impl Localiser {
/// in the second case the same will be done to their chilren instead.
/// [FluentResource]s within a same folder will be considered part of a same [FluentBundle],
/// forming a single localisation for all intents and purposes.
pub fn try_load(path: String, default_language: String) -> Result<Self> {
pub fn try_load(path: &str, default_language: &str) -> Result<Self> {
let mut bundles = HashMap::new();
let mut available_languages = HashMap::new();
let paths = std::fs::read_dir(path)?