From 51f2a23b749b60aae190f9b5980d234843844a8a Mon Sep 17 00:00:00 2001 From: Maxim Krasilnikov Date: Thu, 21 Jun 2018 18:05:49 +0300 Subject: [PATCH] Removed useless goroutines from sync cmd, backFillAllBlocks always called with go func() --- cmd/sync.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/cmd/sync.go b/cmd/sync.go index 9814a41c..6be8d843 100644 --- a/cmd/sync.go +++ b/cmd/sync.go @@ -49,9 +49,7 @@ func init() { } func backFillAllBlocks(blockchain core.Blockchain, blockRepository datastore.BlockRepository, missingBlocksPopulated chan int, startingBlockNumber int64) { - go func() { - missingBlocksPopulated <- history.PopulateMissingBlocks(blockchain, blockRepository, startingBlockNumber) - }() + missingBlocksPopulated <- history.PopulateMissingBlocks(blockchain, blockRepository, startingBlockNumber) } func sync() {