Skip to content
This repository was archived by the owner on Dec 11, 2019. It is now read-only.

Commit 9fca556

Browse files
committed
wrap about actions in setImmediate
1 parent 4124965 commit 9fca556

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

app/ledger.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -269,9 +269,9 @@ var backupKeys = (appState, action) => {
269269
var recoverKeys = (appState, action) => {
270270
client.recoverWallet(action.firstRecoveryKey, action.secondRecoveryKey, (err, body) => {
271271
if (err) {
272-
appActions.ledgerRecoveryFailed()
272+
setImmediate(() => appActions.ledgerRecoveryFailed())
273273
} else {
274-
appActions.ledgerRecoverySucceeded()
274+
setImmediate(() => appActions.ledgerRecoverySucceeded())
275275
}
276276
})
277277

js/about/preferences.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -976,7 +976,7 @@ class PaymentsTab extends ImmutableComponent {
976976
this.props.ledgerData.get('recoverySucceeded') === true
977977
? <div className='recoveryOverlay'>
978978
<h1>Success!</h1>
979-
<p data-l10n-id='balanceRecovered' data-l10n-args={JSON.stringify(l10nDataArgs)} />
979+
<p className='spaceAround' data-l10n-id='balanceRecovered' data-l10n-args={JSON.stringify(l10nDataArgs)} />
980980
<Button l10nId='ok' className='whiteButton inlineButton' onClick={this.clearRecoveryStatus} />
981981
</div>
982982
: null

js/stores/appStore.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -588,10 +588,10 @@ const handleAppAction = (action) => {
588588
appState = appState.setIn(['dictionary', 'locale'], action.locale)
589589
break
590590
case AppConstants.APP_BACKUP_KEYS:
591-
ledger.backupKeys(appState, action)
591+
appState = ledger.backupKeys(appState, action)
592592
break
593593
case AppConstants.APP_RECOVER_WALLET:
594-
ledger.recoverKeys(appState, action)
594+
appState = ledger.recoverKeys(appState, action)
595595
break
596596
case AppConstants.APP_LEDGER_RECOVERY_SUCCEEDED:
597597
appState = appState.setIn(['ui', 'about', 'preferences', 'recoverySucceeded'], true)

0 commit comments

Comments
 (0)