Skip to content
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.

default gas from near-api-js #744

Merged
merged 3 commits into from
Jul 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -817,7 +817,7 @@ Transaction guest-book.testnet:FY8hBam2iyQfdHkdR1dp6w5XEPJzJSosX1wUeVPyUvVK
FunctionCall: {
method_name: 'addMessage',
args: 'eyJ0ZXh0IjoiQWxvaGEifQ==',
gas: 100000000000000,
gas: 300000000000000,
deposit: '0'
}
},
Expand Down
3 changes: 2 additions & 1 deletion bin/near-cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ const yargs = require('yargs');
const main = require('../');
const exitOnError = require('../utils/exit-on-error');
const chalk = require('chalk');
const { DEFAULT_FUNCTION_CALL_GAS } = require('near-api-js');

// For account:

Expand Down Expand Up @@ -112,7 +113,7 @@ const deploy = {
.option('initGas', {
desc: 'Gas for initialization call',
type: 'number',
default: 100000000000000
default: DEFAULT_FUNCTION_CALL_GAS
})
.option('initDeposit', {
desc: 'Deposit in Ⓝ to send for initialization call',
Expand Down
4 changes: 2 additions & 2 deletions commands/call.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const { providers, utils } = require('near-api-js');
const { DEFAULT_FUNCTION_CALL_GAS, providers, utils } = require('near-api-js');
const exitOnError = require('../utils/exit-on-error');
const connect = require('../utils/connect');
const inspectResponse = require('../utils/inspect-response');
Expand All @@ -11,7 +11,7 @@ module.exports = {
.option('gas', {
desc: 'Max amount of gas this call can use (in gas units)',
type: 'string',
default: '100000000000000'
default: DEFAULT_FUNCTION_CALL_GAS
})
.option('deposit', {
desc: 'Number of tokens to attach (in NEAR) to a function call',
Expand Down
3 changes: 2 additions & 1 deletion commands/evm-call.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const { evmDeprecated } = require('../utils/deprecation-warning');
const { DEFAULT_FUNCTION_CALL_GAS } = require('near-api-js');

module.exports = {
command: 'evm-call <evmAccount> <contractName> <methodName> [args]',
Expand All @@ -7,7 +8,7 @@ module.exports = {
.option('gas', {
desc: 'Max amount of NEAR gas this call can use',
type: 'string',
default: '100000000000000'
default: DEFAULT_FUNCTION_CALL_GAS
})
.option('deposit', {
desc: 'Number of tokens to attach',
Expand Down