aboutsummaryrefslogtreecommitdiffstats
path: root/simulation/app.go
diff options
context:
space:
mode:
authorJimmy Hu <jimmy.hu@dexon.org>2018-09-03 10:01:40 +0800
committerGitHub <noreply@github.com>2018-09-03 10:01:40 +0800
commitc8d3092208f73ee991a123052a71b7dbf7fffc27 (patch)
treefdcb3b90b859531e042dbbdd6bcd7b0cca40e86a /simulation/app.go
parent9491ddae81640e04f8aed38e2cddeb64cc62d55b (diff)
downloaddexon-consensus-c8d3092208f73ee991a123052a71b7dbf7fffc27.tar
dexon-consensus-c8d3092208f73ee991a123052a71b7dbf7fffc27.tar.gz
dexon-consensus-c8d3092208f73ee991a123052a71b7dbf7fffc27.tar.bz2
dexon-consensus-c8d3092208f73ee991a123052a71b7dbf7fffc27.tar.lz
dexon-consensus-c8d3092208f73ee991a123052a71b7dbf7fffc27.tar.xz
dexon-consensus-c8d3092208f73ee991a123052a71b7dbf7fffc27.tar.zst
dexon-consensus-c8d3092208f73ee991a123052a71b7dbf7fffc27.zip
core: Add a new structure `Position` and move `ShardID`, `ChainID` and `Height` from `Block` (#89)
Diffstat (limited to 'simulation/app.go')
-rw-r--r--simulation/app.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/simulation/app.go b/simulation/app.go
index f12290c..aded2a7 100644
--- a/simulation/app.go
+++ b/simulation/app.go
@@ -81,7 +81,7 @@ func (a *simApp) getAckedBlocks(ackHash common.Hash) (output common.Hashes) {
return
}
for i, blockHash := range hashes {
- if a.blockByHash[blockHash].Height > ackBlock.Height {
+ if a.blockByHash[blockHash].Position.Height > ackBlock.Position.Height {
output, a.unconfirmedBlocks[ackBlock.ProposerID] = hashes[:i], hashes[i:]
break
}
@@ -95,7 +95,7 @@ func (a *simApp) getAckedBlocks(ackHash common.Hash) (output common.Hashes) {
}
// PreparePayloads implements core.Application.
-func (a *simApp) PreparePayloads(shardID, chainID, height uint64) [][]byte {
+func (a *simApp) PreparePayloads(position types.Position) [][]byte {
return [][]byte{}
}