aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMission Liao <mission.liao@dexon.org>2019-01-29 11:49:14 +0800
committerMission Liao <mission.liao@dexon.org>2019-01-29 12:00:30 +0800
commit4a11711b8acf750a5283f9b223319dffa91797d1 (patch)
tree924a26536e7d1d71a208059394a121bfd614770d
parent5d689c191fdb12de2446bbccd1f7ae6d91f55206 (diff)
downloaddexon-consensus-4a11711b8acf750a5283f9b223319dffa91797d1.tar.gz
dexon-consensus-4a11711b8acf750a5283f9b223319dffa91797d1.tar.zst
dexon-consensus-4a11711b8acf750a5283f9b223319dffa91797d1.zip
Fixup: block hash is empty in signal.
-rw-r--r--core/agreement/signal.go13
1 files changed, 7 insertions, 6 deletions
diff --git a/core/agreement/signal.go b/core/agreement/signal.go
index 0042cd1..03148ed 100644
--- a/core/agreement/signal.go
+++ b/core/agreement/signal.go
@@ -20,8 +20,8 @@ package agreement
import (
"fmt"
+ "github.com/dexon-foundation/dexon-consensus/common"
"github.com/dexon-foundation/dexon-consensus/core/types"
- "github.com/ethereum/go-ethereum/common"
)
// SignalType is the type of agreemnt signal.
@@ -80,10 +80,11 @@ func (s *Signal) String() string {
// NewSignal constructs an Signal instance.
func NewSignal(t SignalType, votes []types.Vote) *Signal {
return &Signal{
- Position: votes[0].Position,
- Period: votes[0].Period,
- Type: t,
- VType: votes[0].Type,
- Votes: votes,
+ Position: votes[0].Position,
+ Period: votes[0].Period,
+ Type: t,
+ VType: votes[0].Type,
+ Votes: votes,
+ BlockHash: votes[0].BlockHash,
}
}