Skip to content

Commit

Permalink
#14102 Remove state if null
Browse files Browse the repository at this point in the history
  • Loading branch information
sandy081 committed Oct 21, 2016
1 parent 8accf62 commit 980fcd3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/vs/workbench/browser/actions/openSettings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -341,12 +341,12 @@ export class DefaultSettingsEditor extends StringEditor {
}

private saveState() {
const resource = this.getResource();
if (DefaultSettingsEditor.VIEW_STATE.has(resource)) {
DefaultSettingsEditor.VIEW_STATE.delete(resource);
}
const state = this.getControl().saveViewState();
if (state) {
const resource = this.getResource();
if (DefaultSettingsEditor.VIEW_STATE.has(resource)) {
DefaultSettingsEditor.VIEW_STATE.delete(resource);
}
DefaultSettingsEditor.VIEW_STATE.set(resource, state);
}
}
Expand Down

0 comments on commit 980fcd3

Please sign in to comment.