Skip to content

Commit

Permalink
Merge pull request #550 from oasisprotocol/pro-wh/feature/holders18
Browse files Browse the repository at this point in the history
config: add evm_nfts_sapphire
  • Loading branch information
pro-wh authored Oct 20, 2023
2 parents 56f78ee + a7e2553 commit c330932
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
13 changes: 13 additions & 0 deletions cmd/analyzer/analyzer.go
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,19 @@ func NewService(cfg *config.AnalysisConfig) (*Service, error) { //nolint:gocyclo
return evmnfts.NewAnalyzer(common.RuntimeEmerald, cfg.Analyzers.EmeraldEvmNfts.ItemBasedAnalyzerConfig, sourceClient, ipfsClient, dbClient, logger)
})
}
if cfg.Analyzers.SapphireEvmNfts != nil {
analyzers, err = addAnalyzer(analyzers, err, func() (A, error) {
sourceClient, err1 := sources.Runtime(ctx, common.RuntimeSapphire)
if err1 != nil {
return nil, err1
}
ipfsClient, err1 := sources.IPFS(ctx)
if err1 != nil {
return nil, err1
}
return evmnfts.NewAnalyzer(common.RuntimeSapphire, cfg.Analyzers.SapphireEvmNfts.ItemBasedAnalyzerConfig, sourceClient, ipfsClient, dbClient, logger)
})
}
if cfg.Analyzers.EmeraldEvmTokenBalances != nil {
runtimeMetadata := cfg.Source.SDKParaTime(common.RuntimeEmerald)
analyzers, err = addAnalyzer(analyzers, err, func() (A, error) {
Expand Down
1 change: 1 addition & 0 deletions config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ type AnalyzersList struct {
EmeraldEvmTokens *EvmTokensAnalyzerConfig `koanf:"evm_tokens_emerald"`
SapphireEvmTokens *EvmTokensAnalyzerConfig `koanf:"evm_tokens_sapphire"`
EmeraldEvmNfts *EvmTokensAnalyzerConfig `koanf:"evm_nfts_emerald"`
SapphireEvmNfts *EvmTokensAnalyzerConfig `koanf:"evm_nfts_sapphire"`
EmeraldEvmTokenBalances *EvmTokensAnalyzerConfig `koanf:"evm_token_balances_emerald"`
SapphireEvmTokenBalances *EvmTokensAnalyzerConfig `koanf:"evm_token_balances_sapphire"`
EmeraldContractCode *EvmContractCodeAnalyzerConfig `koanf:"evm_contract_code_emerald"`
Expand Down

0 comments on commit c330932

Please sign in to comment.