1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

fixed issue with input

This commit is contained in:
brunobar79 2018-08-03 20:11:46 -04:00
parent af97ba103c
commit e9a0feb9e9
3 changed files with 6 additions and 2 deletions

View File

@ -27,6 +27,7 @@ function EnsInput () {
} }
EnsInput.prototype.onChange = function (recipient) { EnsInput.prototype.onChange = function (recipient) {
debugger
const network = this.props.network const network = this.props.network
const networkHasEnsSupport = getNetworkEnsSupport(network) const networkHasEnsSupport = getNetworkEnsSupport(network)

View File

@ -39,6 +39,7 @@ export default class SendTransactionScreen extends PersistentForm {
updateSendErrors: PropTypes.func, updateSendErrors: PropTypes.func,
updateSendTokenBalance: PropTypes.func, updateSendTokenBalance: PropTypes.func,
scanQrCode: PropTypes.func, scanQrCode: PropTypes.func,
qrCodeDetected: PropTypes.func,
qrCodeData: PropTypes.object, qrCodeData: PropTypes.object,
}; };
@ -54,8 +55,8 @@ export default class SendTransactionScreen extends PersistentForm {
if (currentAddress !== scannedAddress) { if (currentAddress !== scannedAddress) {
this.props.updateSendTo(scannedAddress) this.props.updateSendTo(scannedAddress)
this.updateGas({ to: scannedAddress }) this.updateGas({ to: scannedAddress })
// Clean up QR code data after handling
// Here we should clear props.qrCodeData this.props.qrCodeDetected(null)
} }
} }
} }

View File

@ -29,6 +29,7 @@ import {
updateGasData, updateGasData,
setGasTotal, setGasTotal,
showQrScanner, showQrScanner,
qrCodeDetected,
} from '../../actions' } from '../../actions'
import { import {
resetSendState, resetSendState,
@ -98,6 +99,7 @@ function mapDispatchToProps (dispatch) {
updateSendErrors: newError => dispatch(updateSendErrors(newError)), updateSendErrors: newError => dispatch(updateSendErrors(newError)),
resetSendState: () => dispatch(resetSendState()), resetSendState: () => dispatch(resetSendState()),
scanQrCode: () => dispatch(showQrScanner(SEND_ROUTE)), scanQrCode: () => dispatch(showQrScanner(SEND_ROUTE)),
qrCodeDetected: (data) => dispatch(qrCodeDetected(data)),
updateSendTo: (to, nickname) => dispatch(updateSendTo(to, nickname)), updateSendTo: (to, nickname) => dispatch(updateSendTo(to, nickname)),
} }
} }