diff options
author | Wei-Ning Huang <w@cobinhood.com> | 2018-09-26 11:00:04 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@dexon.org> | 2019-04-09 21:32:49 +0800 |
commit | 3e7dcb52f74c9ab4944d92a35a519631a2ec8298 (patch) | |
tree | e5a1895cdbea36cc9ba5e10bb5cfe29f823a8467 /dex/backend.go | |
parent | d056357e4999c6c70c8b8e85a9e4f533895ed6c2 (diff) | |
download | dexon-3e7dcb52f74c9ab4944d92a35a519631a2ec8298.tar dexon-3e7dcb52f74c9ab4944d92a35a519631a2ec8298.tar.gz dexon-3e7dcb52f74c9ab4944d92a35a519631a2ec8298.tar.bz2 dexon-3e7dcb52f74c9ab4944d92a35a519631a2ec8298.tar.lz dexon-3e7dcb52f74c9ab4944d92a35a519631a2ec8298.tar.xz dexon-3e7dcb52f74c9ab4944d92a35a519631a2ec8298.tar.zst dexon-3e7dcb52f74c9ab4944d92a35a519631a2ec8298.zip |
dex: update consensus core interface
Diffstat (limited to 'dex/backend.go')
-rw-r--r-- | dex/backend.go | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/dex/backend.go b/dex/backend.go index 930d7886f..707b1abbb 100644 --- a/dex/backend.go +++ b/dex/backend.go @@ -20,15 +20,15 @@ package dex import ( dexCore "github.com/dexon-foundation/dexon-consensus-core/core" "github.com/dexon-foundation/dexon-consensus-core/core/blockdb" - ethCrypto "github.com/dexon-foundation/dexon-consensus-core/crypto/eth" + "github.com/dexon-foundation/dexon-consensus-core/core/crypto/ecdsa" - "github.com/dexon-foundation/dexon/internal/ethapi" "github.com/dexon-foundation/dexon/accounts" "github.com/dexon-foundation/dexon/consensus" "github.com/dexon-foundation/dexon/core" "github.com/dexon-foundation/dexon/core/bloombits" "github.com/dexon-foundation/dexon/ethdb" "github.com/dexon-foundation/dexon/event" + "github.com/dexon-foundation/dexon/internal/ethapi" "github.com/dexon-foundation/dexon/node" "github.com/dexon-foundation/dexon/p2p" "github.com/dexon-foundation/dexon/params" @@ -77,12 +77,11 @@ func New(ctx *node.ServiceContext, config *Config) (*Dexon, error) { network := NewDexconNetwork() // TODO(w): replace this with node key. - privKey, err := ethCrypto.NewPrivateKey() + privKey, err := ecdsa.NewPrivateKey() if err != nil { panic(err) } - consensus := dexCore.NewConsensus( - app, gov, db, network, privKey, ethCrypto.SigToPub) + consensus := dexCore.NewConsensus(app, gov, db, network, privKey) dex := &Dexon{ config: config, |