feat: fix clippy

This commit is contained in:
2023-10-15 17:01:07 +08:00
parent 66e93106fe
commit bae6ca828d
2 changed files with 4 additions and 4 deletions

View File

@@ -92,7 +92,7 @@ impl TinyEncryptConfig {
pub fn find_by_kid_or_type(&self, k_filter: &str) -> Vec<&TinyEncryptConfigEnvelop> {
self.find_by_kid_or_filter(k_filter, |e| {
k_filter == "ALL" || k_filter == &format!("type:{}", &e.r#type.get_name())
k_filter == "ALL" || k_filter == format!("type:{}", &e.r#type.get_name())
})
}
@@ -121,7 +121,7 @@ impl TinyEncryptConfig {
}
}
if let Some(key_filter) = key_filter {
key_filter.split(",").for_each(|k| {
key_filter.split(',').for_each(|k| {
let k = k.trim();
if !k.is_empty() {
key_ids.push(k.to_string());