mirror of
https://github.com/eosswedenorg/thalos
synced 2026-06-18 04:40:03 +02:00
Merge pull request #17 from eosswedenorg/15-support-chain-names
support chain names
This commit is contained in:
commit
2335dbc211
3 changed files with 13 additions and 1 deletions
|
|
@ -137,6 +137,13 @@ func init() {
|
|||
log.SetFormatter(&formatter)
|
||||
}
|
||||
|
||||
func getChain(def string) string {
|
||||
if len(conf.Ship.Chain) > 0 {
|
||||
return conf.Ship.Chain
|
||||
}
|
||||
return def
|
||||
}
|
||||
|
||||
func main() {
|
||||
var err error
|
||||
var chainInfo *eos.InfoResp
|
||||
|
|
@ -255,7 +262,7 @@ func main() {
|
|||
shClient,
|
||||
api_redis.NewPublisher(rdb, api_redis.Namespace{
|
||||
Prefix: conf.Redis.Prefix,
|
||||
ChainID: chainInfo.ChainID.String(),
|
||||
ChainID: getChain(chainInfo.ChainID.String()),
|
||||
}),
|
||||
abi.NewAbiManager(rdb, eosClient, conf.Redis.CacheID),
|
||||
codec,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue