aboutsummaryrefslogtreecommitdiffstats
path: root/src/federation
diff options
context:
space:
mode:
Diffstat (limited to 'src/federation')
-rw-r--r--src/federation/held.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/federation/held.rs b/src/federation/held.rs
index 985ff45..3ca74a9 100644
--- a/src/federation/held.rs
+++ b/src/federation/held.rs
@@ -783,6 +783,11 @@ impl Holding {
self.party.as_deref()
}
+ /// Whether the node votes for its party by itself (`--store-vote-key`).
+ pub(crate) fn votes_by_itself(&self) -> bool {
+ self.voter.is_some() && self.party.is_some()
+ }
+
/// Itself, the node keeping some of its neighbours among the members of `parties`,
/// with those of its own (`--store-neighbour-parties`).
pub(crate) fn near(self, parties: Vec<String>) -> Self {