mirror of
https://github.com/EasyTier/EasyTier.git
synced 2026-10-08 10:56:13 -08:00
proto: add update method to HeartbeatRequest
This commit is contained in:
1 parent
13aaa437b2
commit
e0897dcf99
1 file changed
+8
@@ -1,7 +1,15 @@
|
||||
use std::fmt::Display;
|
||||
use crate::utils::DeterministicDigest;
|
||||
|
||||
include!(concat!(env!("OUT_DIR"), "/dns.rs"));
|
||||
|
||||
impl HeartbeatRequest {
|
||||
pub fn update(&mut self, snapshot: DnsSnapshot) {
|
||||
self.digest = snapshot.digest();
|
||||
self.snapshot = Some(snapshot);
|
||||
}
|
||||
}
|
||||
|
||||
impl Display for ZoneData {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
writeln!(f, "; EasyTier Magic DNS zone data")?;
|
||||
|
||||
Reference in new issue
Block a user