diff --git a/src/fronious.rs b/src/fronious.rs index 4451b03..bdccd6d 100644 --- a/src/fronious.rs +++ b/src/fronious.rs @@ -1,6 +1,6 @@ use serde::{de::DeserializeOwned, Deserialize, Serialize}; use serde_repr::{Deserialize_repr, Serialize_repr}; -use std::net::IpAddr; +use std::{collections::HashMap, net::IpAddr}; use thiserror::Error; #[derive(Debug, Error)] @@ -54,7 +54,7 @@ pub struct Status { #[derive(Debug, Serialize, Deserialize)] #[serde(rename_all = "PascalCase")] pub struct CommonResponseHeader { - request_arguments: std::collections::HashMap, + request_arguments: HashMap, status: Status, #[serde(with = "time::serde::rfc3339")] timestamp: time::OffsetDateTime, @@ -77,7 +77,7 @@ pub struct CommonResponseBody { #[serde(rename_all = "PascalCase")] pub struct UnitAndValues { unit: String, - values: std::collections::HashMap, + values: HashMap, } #[derive(Debug, Serialize, Deserialize)] @@ -133,7 +133,7 @@ pub struct CumulationInverterData { year_energy: UnitAndValue, total_energy: UnitAndValue, #[serde(rename = "DeviceStatus")] - device_status: Option>, + device_status: Option>, } impl DataCollection for CumulationInverterData {