forked from TrueCloudLab/neoneo-go
native: swap oracle and role management init
Role management doesn't need oracles, but oracles do need role management. See neo-project/neo#2187.
This commit is contained in:
parent
ca86b78536
commit
524bf9aaa0
3 changed files with 9 additions and 9 deletions
|
@ -73,18 +73,18 @@ func NewContracts(p2pSigExtensionsEnabled bool) *Contracts {
|
|||
cs.Policy = policy
|
||||
cs.Contracts = append(cs.Contracts, policy)
|
||||
|
||||
oracle := newOracle()
|
||||
oracle.GAS = gas
|
||||
oracle.NEO = neo
|
||||
cs.Oracle = oracle
|
||||
cs.Contracts = append(cs.Contracts, oracle)
|
||||
|
||||
desig := newDesignate(p2pSigExtensionsEnabled)
|
||||
desig.NEO = neo
|
||||
cs.Designate = desig
|
||||
cs.Oracle.Desig = desig
|
||||
cs.Contracts = append(cs.Contracts, desig)
|
||||
|
||||
oracle := newOracle()
|
||||
oracle.GAS = gas
|
||||
oracle.NEO = neo
|
||||
oracle.Desig = desig
|
||||
cs.Oracle = oracle
|
||||
cs.Contracts = append(cs.Contracts, oracle)
|
||||
|
||||
if p2pSigExtensionsEnabled {
|
||||
notary := newNotary()
|
||||
notary.GAS = gas
|
||||
|
|
|
@ -40,7 +40,7 @@ type oraclesData struct {
|
|||
}
|
||||
|
||||
const (
|
||||
designateContractID = -5
|
||||
designateContractID = -4
|
||||
|
||||
// maxNodeCount is the maximum number of nodes to set the role for.
|
||||
maxNodeCount = 32
|
||||
|
|
|
@ -38,7 +38,7 @@ type Oracle struct {
|
|||
}
|
||||
|
||||
const (
|
||||
oracleContractID = -4
|
||||
oracleContractID = -5
|
||||
maxURLLength = 256
|
||||
maxFilterLength = 128
|
||||
maxCallbackLength = 32
|
||||
|
|
Loading…
Reference in a new issue