2021-06-25 18:13:40 +00:00
|
|
|
package consensusconfig
|
|
|
|
|
|
|
|
import (
|
|
|
|
_ "embed"
|
2021-12-14 10:13:17 +00:00
|
|
|
|
|
|
|
"github.com/ledgerwatch/erigon/params/networkname"
|
2021-06-25 18:13:40 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
//go:embed poasokol.json
|
|
|
|
var Sokol []byte
|
2021-09-27 12:56:17 +00:00
|
|
|
|
2022-07-12 15:21:52 +00:00
|
|
|
//go:embed poagnosis.json
|
|
|
|
var Gnosis []byte
|
|
|
|
|
2021-09-27 12:56:17 +00:00
|
|
|
func GetConfigByChain(chainName string) []byte {
|
|
|
|
switch chainName {
|
2021-12-14 10:13:17 +00:00
|
|
|
case networkname.SokolChainName:
|
2021-09-27 12:56:17 +00:00
|
|
|
return Sokol
|
2022-07-12 15:21:52 +00:00
|
|
|
case networkname.GnosisChainName:
|
|
|
|
return Gnosis
|
2021-09-27 12:56:17 +00:00
|
|
|
default:
|
|
|
|
return Sokol
|
|
|
|
}
|
|
|
|
}
|