fix: silence in the master library

This commit is contained in:
Cassandra Heart 2024-03-09 20:54:00 -06:00
parent 24a17ceddb
commit ee1ebcce80
No known key found for this signature in database
GPG Key ID: 6352152859385958

View File

@ -300,11 +300,16 @@ func (e *MasterClockConsensusEngine) publishProof(
e.masterTimeReel.Insert(frame)
if err := e.publishMessage(e.filter, frame); err != nil {
return errors.Wrap(
err,
"publish proof",
)
peers, err := e.GetMostAheadPeers()
if err != nil || len(peers) == 0 {
// publish if we don't see anyone (empty peer list) or if we're the most
// ahead:
if err := e.publishMessage(e.filter, frame); err != nil {
return errors.Wrap(
err,
"publish proof",
)
}
}
e.state = consensus.EngineStateCollecting