use method `.call` only for the read methods
- review screen then will attempt to evaluate the validity of the write method
This commit is contained in:
parent
adfbcdfd19
commit
b07f0e90d9
|
@ -38,9 +38,9 @@ const ContractInteraction = ({ contractAddress, initialValues, onClose, onNext }
|
||||||
try {
|
try {
|
||||||
const txObject = createTxObject(selectedMethod, contractAddress, values)
|
const txObject = createTxObject(selectedMethod, contractAddress, values)
|
||||||
const data = txObject.encodeABI()
|
const data = txObject.encodeABI()
|
||||||
const result = await txObject.call({ from: safeAddress })
|
|
||||||
|
|
||||||
if (isReadMethod(selectedMethod)) {
|
if (isReadMethod(selectedMethod)) {
|
||||||
|
const result = await txObject.call({ from: safeAddress })
|
||||||
setCallResults(result)
|
setCallResults(result)
|
||||||
|
|
||||||
// this was a read method, so we won't go to the 'review' screen
|
// this was a read method, so we won't go to the 'review' screen
|
||||||
|
|
Loading…
Reference in New Issue