Skip to content

Commit 15af44e

Browse files
authored
fix updating options (microsoft#188132)
1 parent c235b9c commit 15af44e

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

src/vs/workbench/contrib/userDataProfile/browser/userDataProfile.ts

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -542,17 +542,11 @@ export class UserDataProfilesWorkbenchContribution extends Disposable implements
542542
quickPick.widget = domNode;
543543

544544
const updateOptions = () => {
545-
const index = findOptionIndex();
546-
if (index <= 0) {
547-
return;
548-
}
549-
const option = profileOptions[index];
550-
if (!isString(option.source)) {
551-
for (const resource of resources) {
552-
resource.picked = option.source?.useDefaultFlags?.[resource.id];
553-
}
554-
update();
545+
const option = profileOptions[findOptionIndex()];
546+
for (const resource of resources) {
547+
resource.picked = option.source && !isString(option.source) ? !option.source?.useDefaultFlags?.[resource.id] : true;
555548
}
549+
update();
556550
};
557551

558552
updateOptions();

0 commit comments

Comments
 (0)