Skip to content

Commit

Permalink
refactor: ContractConfig - Amount added, Gas/GasPrice as BigInt
Browse files Browse the repository at this point in the history
  • Loading branch information
randomshinichi committed May 27, 2019
1 parent a072966 commit 3ab86f5
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions aeternity/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,12 @@ type AensConfig struct {

// ContractConfig configurations for contracts
type ContractConfig struct {
Gas uint64 `json:"gas" yaml:"gas" mapstructure:"gas"`
GasPrice uint64 `json:"gas_price" yaml:"gas_price" mapstructure:"gas_price"`
Deposit uint64 `json:"deposit" yaml:"deposit" mapstructure:"deposit"`
VMVersion uint64 `json:"vm_version" yaml:"vm_version" mapstructure:"vm_version"`
ABIVersion uint64 `json:"abi_version" yaml:"abi_version" mapstructure:"abi_version"`
Gas utils.BigInt `json:"gas" yaml:"gas" mapstructure:"gas"`
GasPrice utils.BigInt `json:"gas_price" yaml:"gas_price" mapstructure:"gas_price"`
Amount utils.BigInt `json:"amount" yaml:"amount" mapstructure:"amount"`
Deposit uint64 `json:"deposit" yaml:"deposit" mapstructure:"deposit"`
VMVersion uint64 `json:"vm_version" yaml:"vm_version" mapstructure:"vm_version"`
ABIVersion uint64 `json:"abi_version" yaml:"abi_version" mapstructure:"abi_version"`
}

// OracleConfig configurations for contracts
Expand Down Expand Up @@ -108,11 +109,12 @@ var Config = ProfileConfig{
UpdateFee: *utils.RequireBigIntFromString("100000000000000"),
},
Contracts: ContractConfig{
Gas: 1e9,
GasPrice: 1e9,
Gas: *utils.NewBigIntFromUint64(1e9),
GasPrice: *utils.NewBigIntFromUint64(1e9),
Amount: *utils.NewBigInt(),
Deposit: 0,
VMVersion: 0,
ABIVersion: 2,
VMVersion: 3,
ABIVersion: 1,
},
Oracles: OracleConfig{
QueryFee: *utils.NewBigIntFromUint64(0),
Expand Down

0 comments on commit 3ab86f5

Please sign in to comment.