Remove unused nodeconfig.SetConfigs

pull/1939/head
Eugene Kim 5 years ago
parent 3bee63e9d9
commit 878e13ba8c
  1. 13
      internal/configs/node/config.go

@ -5,7 +5,6 @@ package nodeconfig
import (
"crypto/ecdsa"
"errors"
"fmt"
"sync"
@ -111,18 +110,6 @@ func GetShardConfig(shardID uint32) *ConfigType {
return &shardConfigs[shardID]
}
// SetConfigs set ConfigType in the right index.
func SetConfigs(config ConfigType, shardID uint32) error {
onceForConfigs.Do(func() {
shardConfigs = make([]ConfigType, MaxShards)
})
if int(shardID) >= cap(shardConfigs) {
return errors.New("Failed to set ConfigType")
}
shardConfigs[int(shardID)] = config
return nil
}
// GetDefaultConfig returns default config.
func GetDefaultConfig() *ConfigType {
return &defaultConfig

Loading…
Cancel
Save