mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Prevent multiple submissions of first time form
This commit is contained in:
parent
65cb970487
commit
597af980dd
@ -8,6 +8,8 @@ const actions = require('../actions')
|
|||||||
const Tooltip = require('../components/tooltip')
|
const Tooltip = require('../components/tooltip')
|
||||||
const getCaretCoordinates = require('textarea-caret')
|
const getCaretCoordinates = require('textarea-caret')
|
||||||
|
|
||||||
|
let isSubmitting = false
|
||||||
|
|
||||||
module.exports = connect(mapStateToProps)(InitializeMenuScreen)
|
module.exports = connect(mapStateToProps)(InitializeMenuScreen)
|
||||||
|
|
||||||
inherits(InitializeMenuScreen, Component)
|
inherits(InitializeMenuScreen, Component)
|
||||||
@ -164,7 +166,10 @@ InitializeMenuScreen.prototype.createNewVaultAndKeychain = function () {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!isSubmitting) {
|
||||||
|
isSubmitting = true
|
||||||
this.props.dispatch(actions.createNewVaultAndKeychain(password))
|
this.props.dispatch(actions.createNewVaultAndKeychain(password))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
InitializeMenuScreen.prototype.inputChanged = function (event) {
|
InitializeMenuScreen.prototype.inputChanged = function (event) {
|
||||||
|
Loading…
Reference in New Issue
Block a user