cargo fmt

This commit is contained in:
houseme
2025-06-27 18:53:51 +08:00
parent 8a4cb0319a
commit 7bd8431006
12 changed files with 29 additions and 55 deletions
+1 -2
View File
@@ -241,8 +241,7 @@ impl MQTTTarget {
records: vec![event.clone()],
};
let data =
serde_json::to_vec(&log).map_err(|e| TargetError::Serialization(format!("Failed to serialize event: {e}")))?;
let data = serde_json::to_vec(&log).map_err(|e| TargetError::Serialization(format!("Failed to serialize event: {e}")))?;
// Vec<u8> Convert to String, only for printing logs
let data_string = String::from_utf8(data.clone())
+1 -2
View File
@@ -206,8 +206,7 @@ impl WebhookTarget {
records: vec![event.clone()],
};
let data =
serde_json::to_vec(&log).map_err(|e| TargetError::Serialization(format!("Failed to serialize event: {e}")))?;
let data = serde_json::to_vec(&log).map_err(|e| TargetError::Serialization(format!("Failed to serialize event: {e}")))?;
// Vec<u8> Convert to String
let data_string = String::from_utf8(data.clone())