aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/dexon-foundation/dexon-consensus/core/agreement-mgr.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/dexon-foundation/dexon-consensus/core/agreement-mgr.go')
-rw-r--r--vendor/github.com/dexon-foundation/dexon-consensus/core/agreement-mgr.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/vendor/github.com/dexon-foundation/dexon-consensus/core/agreement-mgr.go b/vendor/github.com/dexon-foundation/dexon-consensus/core/agreement-mgr.go
index 979045223..7006242b1 100644
--- a/vendor/github.com/dexon-foundation/dexon-consensus/core/agreement-mgr.go
+++ b/vendor/github.com/dexon-foundation/dexon-consensus/core/agreement-mgr.go
@@ -199,6 +199,11 @@ func (mgr *agreementMgr) notifyRoundEvents(evts []utils.RoundEventParam) error {
if len(mgr.configs) > 0 {
lastCfg := mgr.configs[len(mgr.configs)-1]
if e.BeginHeight != lastCfg.RoundEndHeight() {
+ // the init config of BA part is provided when constructing.
+ if len(mgr.configs) == 1 &&
+ e.BeginHeight == lastCfg.LastPeriodBeginHeight() {
+ return nil
+ }
return ErrInvalidBlockHeight
}
if lastCfg.RoundID() == e.Round {