Skip to content

Commit

Permalink
Update main.go
Browse files Browse the repository at this point in the history
  • Loading branch information
SimiHunjan authored Oct 28, 2021
1 parent dd36df7 commit 4006f3e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions examples/create_stateful_contract/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ func main() {
// Instantiate the contract instance
contractTransactionID, err := hedera.NewContractCreateTransaction().
// Failing to set this to a sufficient amount will result in "INSUFFICIENT_GAS" status
SetGas(2000).
SetGas(75000).
// Failing to set parameters when required will result in "CONTRACT_REVERT_EXECUTED" status
SetConstructorParameters(contractFunctionParams).
SetBytecodeFileID(byteCodeFileID).
Expand Down Expand Up @@ -129,7 +129,7 @@ func main() {
// Ask for the current message (set on creation)
callResult, err := hedera.NewContractCallQuery().
SetContractID(newContractID).
SetGas(1000).
SetGas(75000).
SetQueryPayment(hedera.NewHbar(1)).
// nil -> no parameters
SetFunction("getMessage", nil).
Expand All @@ -148,7 +148,7 @@ func main() {
// Update the message
contractExecuteID, err := hedera.NewContractExecuteTransaction().
SetContractID(newContractID).
SetGas(7000).
SetGas(75000).
SetFunction("setMessage", contractFunctionParams).
Execute(client)

Expand All @@ -173,7 +173,7 @@ func main() {

secondCallResult, err := hedera.NewContractCallQuery().
SetContractID(newContractID).
SetGas(1000).
SetGas(75000).
SetQueryPayment(hedera.NewHbar(1)).
SetFunction("getMessage", nil).
Execute(client)
Expand Down

0 comments on commit 4006f3e

Please sign in to comment.