github.com/SmartMeshFoundation/Spectrum@v0.0.0-20220621030607-452a266fee1e/params/nomination_params.go (about) 1 package params 2 3 import ( 4 "crypto/ecdsa" 5 "github.com/SmartMeshFoundation/Spectrum/common" 6 "github.com/SmartMeshFoundation/Spectrum/crypto" 7 "github.com/SmartMeshFoundation/Spectrum/log" 8 ) 9 10 var exclude = map[common.Address]bool{ 11 common.HexToAddress("0x3a5fBaC6CA913599C5fde8c1638dB58d01De8A48"): true, 12 common.HexToAddress("0xAd4c80164065a3c33dD2014908c7563eFf88Ab49"): true, 13 common.HexToAddress("0xc22D53456ABd14Da347517a4B47ea24866B8E3Ae"): true, 14 } 15 16 // genesis node do not can be nomination 17 func CanNomination(key *ecdsa.PublicKey) bool { 18 addr := crypto.PubkeyToAddress(*key) 19 log.Debug("fetchVolunteer_callback.CanNomination ", "addr", addr.Hex(), "exclude", exclude[addr]) 20 if exclude[addr] { 21 return false 22 } 23 return true 24 }