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

Commit

Permalink
Delete "defaultBrowserCheckComplete" only when check on startup is on
Browse files Browse the repository at this point in the history
fix #4934

Auditors: @bbondy

Test Plan:
1. Turn off always check on startup
2. Close app
3. Open app
4. Go to preferences
5. Toggle the switch for always check on startup
  • Loading branch information
darkdh committed Oct 19, 2016
1 parent 497ecf8 commit 449e40d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions app/renderer/components/checkDefaultBrowserDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,13 @@ class CheckDefaultBrowserDialog extends ImmutableComponent {
appActions.defaultBrowserUpdated(false)
appActions.defaultBrowserCheckComplete()
appActions.changeSetting(settings.CHECK_DEFAULT_ON_STARTUP, this.props.checkDefaultOnStartup)
this.props.onHide()
}
onUseBrave () {
appActions.defaultBrowserUpdated(true)
appActions.defaultBrowserCheckComplete()
appActions.changeSetting(settings.CHECK_DEFAULT_ON_STARTUP, this.props.checkDefaultOnStartup)
this.props.onHide()
}
render () {
return <Dialog className='checkDefaultBrowserDialog' >
Expand Down
6 changes: 4 additions & 2 deletions app/sessionStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -234,8 +234,10 @@ module.exports.cleanAppData = (data, isShutdown) => {
data.temporarySiteSettings = {}
// Delete Flash state since this is checked on startup
delete data.flashInitialized
// Delete defaultBrowserCheckComplete state since this is checked on startup
delete data.defaultBrowserCheckComplete
if (data.settings[settings.CHECK_DEFAULT_ON_STARTUP] === true) {
// Delete defaultBrowserCheckComplete state since this is checked on startup
delete data.defaultBrowserCheckComplete
}
// Delete Recovery status on shut down
try {
delete data.ui.about.preferences.recoverySucceeded
Expand Down

0 comments on commit 449e40d

Please sign in to comment.