Skip to content

Commit

Permalink
fix: clippy error
Browse files Browse the repository at this point in the history
  • Loading branch information
fukusuket committed Oct 22, 2024
1 parent 5b6790c commit 240f80f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/detections/detection.rs
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ impl Detection {
.replace_all(
stored_static
.ch_config
.get(&CompactString::from(ch_str.to_ascii_lowercase()))
.get(&ch_str.to_ascii_lowercase())
.unwrap_or(ch_str)
.as_str(),
&stored_static.disp_abbr_general_values,
Expand Down Expand Up @@ -722,7 +722,7 @@ impl Detection {
FieldDataMapKey::default()
} else {
FieldDataMapKey {
channel: CompactString::from(ch_str.clone().to_lowercase()),
channel: ch_str.clone().to_lowercase(),
event_id: eid.clone(),
}
};
Expand Down Expand Up @@ -1160,8 +1160,8 @@ impl Detection {
let enable_deprecated_flag = output_opt.enable_deprecated_rules;
let enable_unsupported_flag = output_opt.enable_unsupported_rules;
let is_filtered_rule_flag = |x: &CompactString| {
x == &"deprecated" && !enable_deprecated_flag
|| x == &"unsupported" && !enable_unsupported_flag
x == "deprecated" && !enable_deprecated_flag
|| x == "unsupported" && !enable_unsupported_flag
};
let total_loaded_rule_cnt: u128 = sorted_st_rc
.iter()
Expand Down
2 changes: 1 addition & 1 deletion src/timeline/search.rs
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ pub fn search_result_dsp_msg(
let abbr_channel = stored_static.disp_abbr_generic.replace_all(
stored_static
.ch_config
.get(&CompactString::from(channel.to_ascii_lowercase()))
.get(&channel.to_ascii_lowercase())
.unwrap_or(&channel)
.as_str(),
&stored_static.disp_abbr_general_values,
Expand Down

0 comments on commit 240f80f

Please sign in to comment.