aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMission Liao <mission.liao@dexon.org>2019-04-12 21:42:44 +0800
committerMission Liao <mission.liao@dexon.org>2019-04-15 14:41:19 +0800
commit1f44d2015c892a1f9a68a829ae1bbb222131d66d (patch)
treea655904c858385b43730a99eed7bddd58f484fdc
parent7d51e26e82650f1e5483c69f240759b9792c316b (diff)
downloaddexon-consensus-1f44d2015c892a1f9a68a829ae1bbb222131d66d.tar.gz
dexon-consensus-1f44d2015c892a1f9a68a829ae1bbb222131d66d.tar.zst
dexon-consensus-1f44d2015c892a1f9a68a829ae1bbb222131d66d.zip
Fixup: remove Vote.Newer
-rw-r--r--core/types/vote.go6
1 files changed, 0 insertions, 6 deletions
diff --git a/core/types/vote.go b/core/types/vote.go
index d935e7d..8bb27c1 100644
--- a/core/types/vote.go
+++ b/core/types/vote.go
@@ -115,9 +115,3 @@ func (v *Vote) Clone() *Vote {
Signature: v.Signature.Clone(),
}
}
-
-// Newer return true when the (position, period) of other vote is older than us.
-func (v Vote) Newer(other Vote) bool {
- return v.Position.Newer(other.Position) ||
- (v.Position.Equal(other.Position) && v.Period > other.Period)
-}