Skip to content

Commit e69176a

Browse files
authored
1 parent 2a745e6 commit e69176a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,6 @@ export class UserDataProfilesWorkbenchContribution extends Disposable implements
118118
id: `workbench.profiles.actions.profileEntry.${profile.id}`,
119119
title: profile.name,
120120
toggled: ContextKeyExpr.equals(CONTEXT_CURRENT_PROFILE.key, profile.id),
121-
precondition: ContextKeyExpr.notEquals(CONTEXT_CURRENT_PROFILE.key, profile.id),
122121
menu: [
123122
{
124123
id: ManageProfilesSubMenu,
@@ -129,7 +128,9 @@ export class UserDataProfilesWorkbenchContribution extends Disposable implements
129128
});
130129
}
131130
async run(accessor: ServicesAccessor) {
132-
return that.userDataProfileManagementService.switchProfile(profile);
131+
if (that.userDataProfileService.currentProfile.id !== profile.id) {
132+
return that.userDataProfileManagementService.switchProfile(profile);
133+
}
133134
}
134135
});
135136
}

0 commit comments

Comments
 (0)