forked from cerc-io/ipld-eth-server
use Debugf instead of strconv
This commit is contained in:
parent
5a1f599a4d
commit
74a90fd124
@ -18,7 +18,6 @@ package watcher
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
"github.com/ethereum/go-ethereum/common"
|
||||
@ -124,7 +123,7 @@ func (storageWatcher StorageWatcher) processRow(diff utils.StorageDiff) {
|
||||
}
|
||||
return
|
||||
}
|
||||
logrus.Debug("Storage diff persisted at block height: " + strconv.Itoa(diff.BlockHeight))
|
||||
logrus.Debugf("Storage diff persisted at block height: %d", diff.BlockHeight)
|
||||
}
|
||||
|
||||
func (storageWatcher StorageWatcher) processQueue() {
|
||||
|
@ -60,7 +60,7 @@ func NewBlockChain(ethClient core.EthClient, rpcClient core.RPCClient, node core
|
||||
|
||||
func (blockChain *BlockChain) GetBlockByNumber(blockNumber int64) (block core.Block, err error) {
|
||||
gethBlock, err := blockChain.ethClient.BlockByNumber(context.Background(), big.NewInt(blockNumber))
|
||||
logrus.Debug("GetBlockByNumber called with block " + strconv.Itoa(int(blockNumber)))
|
||||
logrus.Debugf("GetBlockByNumber called with block %d", blockNumber)
|
||||
if err != nil {
|
||||
return block, err
|
||||
}
|
||||
@ -77,7 +77,7 @@ func (blockChain *BlockChain) GetEthLogsWithCustomQuery(query ethereum.FilterQue
|
||||
}
|
||||
|
||||
func (blockChain *BlockChain) GetHeaderByNumber(blockNumber int64) (header core.Header, err error) {
|
||||
logrus.Debug("GetHeaderByNumber called with block " + strconv.Itoa(int(blockNumber)))
|
||||
logrus.Debugf("GetHeaderByNumber called with block %d", blockNumber)
|
||||
if blockChain.node.NetworkID == core.KOVAN_NETWORK_ID {
|
||||
return blockChain.getPOAHeader(blockNumber)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user