Set rfId instead of channelId

Missing `:`

Missing `None`
This commit is contained in:
Andrew committed 2023-04-03 17:15:00 +07:00
1 parent 82a39a2fa1
commit ca5de6445d
2 files changed
+6 -2

No files matched your search

+4
View File
@@ -238,6 +238,9 @@ pub struct Extension {
/// The channel ID. This is usually `0` unless using an NVR
#[yaserde(rename = "channelId")]
pub channel_id: Option<u8>,
/// The rfID used in the PIR
#[yaserde(rename = "rfId")]
pub rf_id: Option<u8>,
}
impl Default for Extension {
@@ -248,6 +251,7 @@ impl Default for Extension {
user_name: None,
token: None,
channel_id: None,
rf_id: None,
}
}
}
+2 -2
View File
@@ -18,7 +18,7 @@ impl BcCamera {
},
body: BcBody::ModernMsg(ModernMsg {
extension: Some(Extension {
channel_id: Some(self.channel_id),
rf_id: Some(self.channel_id),
..Default::default()
}),
payload: None,
@@ -66,7 +66,7 @@ impl BcCamera {
},
body: BcBody::ModernMsg(ModernMsg {
extension: Some(Extension {
channel_id: Some(self.channel_id),
rf_id: Some(self.channel_id),
..Default::default()
}),
payload: Some(BcPayloads::BcXml(BcXml {