Merge pull request #319 from poanetwork/vb-check-state-mutability
Check stateMutability prop to define if this is reading method
This commit is contained in:
commit
7e40ea91b7
|
@ -161,9 +161,10 @@ class SendTransactionScreen extends PersistentForm {
|
|||
options={this.state.options}
|
||||
style={{ marginBottom: '10px' }}
|
||||
onChange={(opt) => {
|
||||
const isConstantMethod = opt.metadata && (opt.metadata.constant || opt.metadata.stateMutability === 'view')
|
||||
this.setState({
|
||||
methodSelected: opt.value,
|
||||
isConstantMethod: opt.metadata.constant,
|
||||
isConstantMethod: isConstantMethod,
|
||||
methodABI: opt.metadata,
|
||||
outputValues: {},
|
||||
inputValues: {},
|
||||
|
|
Loading…
Reference in New Issue