aboutsummaryrefslogtreecommitdiffstats
path: root/core/database_util.go
diff options
context:
space:
mode:
authorchanghong <changhong.yu@shanbay.com>2017-05-11 09:55:48 +0800
committerPéter Szilágyi <peterke@gmail.com>2017-05-25 22:14:33 +0800
commit17f0b1194232ebebc4e14f905e6e1d2d148aa5b6 (patch)
tree60663b43bff6e8df5b5a4693cbabc7756482136e /core/database_util.go
parent07aae19e5da66ed404453e6be70ab84db516207b (diff)
downloadgo-tangerine-17f0b1194232ebebc4e14f905e6e1d2d148aa5b6.tar
go-tangerine-17f0b1194232ebebc4e14f905e6e1d2d148aa5b6.tar.gz
go-tangerine-17f0b1194232ebebc4e14f905e6e1d2d148aa5b6.tar.bz2
go-tangerine-17f0b1194232ebebc4e14f905e6e1d2d148aa5b6.tar.lz
go-tangerine-17f0b1194232ebebc4e14f905e6e1d2d148aa5b6.tar.xz
go-tangerine-17f0b1194232ebebc4e14f905e6e1d2d148aa5b6.tar.zst
go-tangerine-17f0b1194232ebebc4e14f905e6e1d2d148aa5b6.zip
core: typos and comments improve
1. fix typos 2. methods recevier of struct should be same 3. comments improve (cherry picked from commit 1ba979539582a00b7fd1a7c8a37a6852e59eac0d)
Diffstat (limited to 'core/database_util.go')
-rw-r--r--core/database_util.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/database_util.go b/core/database_util.go
index bcd99be5f..b4a230c9c 100644
--- a/core/database_util.go
+++ b/core/database_util.go
@@ -64,7 +64,7 @@ var (
oldBlockReceiptsPrefix = []byte("receipts-block-")
oldBlockHashPrefix = []byte("block-hash-") // [deprecated by the header/block split, remove eventually]
- ChainConfigNotFoundErr = errors.New("ChainConfig not found") // general config not found error
+ ErrChainConfigNotFound = errors.New("ChainConfig not found") // general config not found error
mipmapBloomMu sync.Mutex // protect against race condition when updating mipmap blooms
@@ -546,7 +546,7 @@ func mipmapKey(num, level uint64) []byte {
return append(mipmapPre, append(lkey, key.Bytes()...)...)
}
-// WriteMapmapBloom writes each address included in the receipts' logs to the
+// WriteMipmapBloom writes each address included in the receipts' logs to the
// MIP bloom bin.
func WriteMipmapBloom(db ethdb.Database, number uint64, receipts types.Receipts) error {
mipmapBloomMu.Lock()
@@ -638,7 +638,7 @@ func WriteChainConfig(db ethdb.Database, hash common.Hash, cfg *params.ChainConf
func GetChainConfig(db ethdb.Database, hash common.Hash) (*params.ChainConfig, error) {
jsonChainConfig, _ := db.Get(append(configPrefix, hash[:]...))
if len(jsonChainConfig) == 0 {
- return nil, ChainConfigNotFoundErr
+ return nil, ErrChainConfigNotFound
}
var config params.ChainConfig