diff options
author | Nick Johnson <arachnid@notdot.net> | 2017-06-27 23:15:29 +0800 |
---|---|---|
committer | Nick Johnson <arachnid@notdot.net> | 2017-06-28 22:58:41 +0800 |
commit | 055095798911e3c6f2e210220cb7ece1b71f6517 (patch) | |
tree | 27f22dcec90015971a464b15ca8d73736756906d /les | |
parent | dfd076244dd0c2d809f9dd0080feab167ba9560c (diff) | |
download | dexon-055095798911e3c6f2e210220cb7ece1b71f6517.tar.gz dexon-055095798911e3c6f2e210220cb7ece1b71f6517.tar.zst dexon-055095798911e3c6f2e210220cb7ece1b71f6517.zip |
eth, les, light: Refactor downloader to use blockchain interface
Diffstat (limited to 'les')
-rw-r--r-- | les/handler.go | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/les/handler.go b/les/handler.go index 77bc077a2..afd4356ef 100644 --- a/les/handler.go +++ b/les/handler.go @@ -206,9 +206,7 @@ func NewProtocolManager(chainConfig *params.ChainConfig, lightSync bool, network } if lightSync { - manager.downloader = downloader.New(downloader.LightSync, chainDb, manager.eventMux, blockchain.HasHeader, nil, blockchain.GetHeaderByHash, - nil, blockchain.CurrentHeader, nil, nil, nil, blockchain.GetTdByHash, - blockchain.InsertHeaderChain, nil, nil, blockchain.Rollback, removePeer) + manager.downloader = downloader.New(downloader.LightSync, chainDb, manager.eventMux, nil, blockchain, removePeer) manager.peers.notify((*downloaderPeerNotify)(manager)) manager.fetcher = newLightFetcher(manager) } |