mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 15:16:43 +00:00
core/filtermaps: rename NoHistory -> Disabled
This commit is contained in:
parent
608056a34a
commit
2131db4fd7
2 changed files with 5 additions and 5 deletions
|
|
@ -168,8 +168,8 @@ type lastBlockOfMap struct {
|
||||||
|
|
||||||
// Config contains the configuration options for NewFilterMaps.
|
// Config contains the configuration options for NewFilterMaps.
|
||||||
type Config struct {
|
type Config struct {
|
||||||
History uint64 // number of historical blocks to index
|
History uint64 // number of historical blocks to index
|
||||||
NoHistory bool // disables indexing completely
|
Disabled bool // disables indexing completely
|
||||||
|
|
||||||
// This option enables the checkpoint JSON file generator.
|
// This option enables the checkpoint JSON file generator.
|
||||||
// If set, the given file will be updated with checkpoint information.
|
// If set, the given file will be updated with checkpoint information.
|
||||||
|
|
@ -191,7 +191,7 @@ func NewFilterMaps(db ethdb.KeyValueStore, initView *ChainView, params Params, c
|
||||||
finalBlockCh: make(chan uint64, 1),
|
finalBlockCh: make(chan uint64, 1),
|
||||||
blockProcessingCh: make(chan bool, 1),
|
blockProcessingCh: make(chan bool, 1),
|
||||||
history: config.History,
|
history: config.History,
|
||||||
noHistory: config.NoHistory,
|
noHistory: config.Disabled,
|
||||||
exportFileName: config.ExportFileName,
|
exportFileName: config.ExportFileName,
|
||||||
Params: params,
|
Params: params,
|
||||||
indexedRange: filterMapsRange{
|
indexedRange: filterMapsRange{
|
||||||
|
|
|
||||||
|
|
@ -232,8 +232,8 @@ func (ts *testSetup) setHistory(history uint64, noHistory bool) {
|
||||||
head := ts.chain.CurrentBlock()
|
head := ts.chain.CurrentBlock()
|
||||||
view := NewChainView(ts.chain, head.Number.Uint64(), head.Hash())
|
view := NewChainView(ts.chain, head.Number.Uint64(), head.Hash())
|
||||||
config := Config{
|
config := Config{
|
||||||
History: history,
|
History: history,
|
||||||
NoHistory: noHistory,
|
Disabled: noHistory,
|
||||||
}
|
}
|
||||||
ts.fm = NewFilterMaps(ts.db, view, ts.params, config)
|
ts.fm = NewFilterMaps(ts.db, view, ts.params, config)
|
||||||
ts.fm.testDisableSnapshots = ts.testDisableSnapshots
|
ts.fm.testDisableSnapshots = ts.testDisableSnapshots
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue