bugfix (@embark/stack/embarkjs): set default gas so it's an optional parameter for onDeploy directives in the contracts config

This commit is contained in:
Iuri Matias 2019-11-12 16:06:52 -05:00
parent aecb99d428
commit af51e2d793
2 changed files with 4 additions and 1 deletions

View File

@ -22,7 +22,7 @@ module.exports = {
SimpleStorage: {
fromIndex: 0,
args: [100],
onDeploy: ["SimpleStorage.methods.setRegistar('embark.eth').send({from: web3.eth.defaultAccount})"]
onDeploy: ["SimpleStorage.methods.setRegistar('embark.eth').send()"]
},
SimpleStorageTest: {
//file: "./some_folder/test_contract.sol",

View File

@ -1,2 +1,5 @@
<%- className %>Config = <%- JSON.stringify(contract) %>;
<%- className %> = new EmbarkJS.Blockchain.Contract(<%- className %>Config);
if (!<%- className %>.options.gas) {
<%- className %>.options.gas = 800000;
}