From 7332a774be92b150971bc599e257e75b5316e7e4 Mon Sep 17 00:00:00 2001 From: DustInDark Date: Thu, 9 Jun 2022 01:11:20 +0900 Subject: [PATCH] cargo fmt --- src/detections/print.rs | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/detections/print.rs b/src/detections/print.rs index b3117093..9f5dc78e 100644 --- a/src/detections/print.rs +++ b/src/detections/print.rs @@ -173,12 +173,16 @@ impl Message { } } let suffix_match = SUFFIXREGEX.captures(&target_str); - let suffix:i64 = match suffix_match{ + let suffix: i64 = match suffix_match { Some(cap) => cap.get(1).map_or(-1, |a| a.as_str().parse().unwrap_or(-1)), - None => -1 + None => -1, }; if suffix >= 0 { - tmp_event_record = tmp_event_record.get("Data").unwrap().get(suffix as usize).unwrap_or(tmp_event_record); + tmp_event_record = tmp_event_record + .get("Data") + .unwrap() + .get(suffix as usize) + .unwrap_or(tmp_event_record); } let hash_value = get_serde_number_to_string(tmp_event_record); if hash_value.is_some() {