From 5d807a1874b31dcec18e43b9d03fb5e428796c4e Mon Sep 17 00:00:00 2001 From: Eduard Voiculescu Date: Fri, 18 Oct 2024 14:07:15 -0400 Subject: [PATCH] Removing global registry --- x/evm/tracers/firehose.go | 1 - x/evm/tracers/registry.go | 8 -------- 2 files changed, 9 deletions(-) diff --git a/x/evm/tracers/firehose.go b/x/evm/tracers/firehose.go index a302974203..1f07055a35 100644 --- a/x/evm/tracers/firehose.go +++ b/x/evm/tracers/firehose.go @@ -68,7 +68,6 @@ func init() { staticFirehoseChainValidationOnInit() tracers.LiveDirectory.Register("firehose", newFirehoseTracer) - GlobalLiveTracerRegistry.Register("firehose", NewCosmosFirehoseTracer) // Those 2 are defined but not used in this branch, they are kept because used in other branches // so it's easier to keep them here and suppress the warning by faking a usage. diff --git a/x/evm/tracers/registry.go b/x/evm/tracers/registry.go index 71731343dd..36d47e129d 100644 --- a/x/evm/tracers/registry.go +++ b/x/evm/tracers/registry.go @@ -1,7 +1,5 @@ package tracers -var GlobalLiveTracerRegistry = NewLiveTracerRegistry() - type LiveTracerRegistry interface { GetFactoryByID(id string) (BlockchainTracerFactory, bool) Register(id string, factory BlockchainTracerFactory) @@ -9,12 +7,6 @@ type LiveTracerRegistry interface { var _ LiveTracerRegistry = (*liveTracerRegistry)(nil) -func NewLiveTracerRegistry() LiveTracerRegistry { - return &liveTracerRegistry{ - tracers: make(map[string]BlockchainTracerFactory), - } -} - type liveTracerRegistry struct { tracers map[string]BlockchainTracerFactory }