mirror of
https://github.com/EasyTier/EasyTier.git
synced 2026-08-07 04:59:49 +00:00
proto: add update method to HeartbeatRequest
This commit is contained in:
@@ -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