Skip to content

Commit 85fff31

Browse files
committed
Improves description for a case when default target is undefined
(#4224, #4258)
1 parent 31dd3ec commit 85fff31

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/commands/changeBranchMergeTarget.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ export class ChangeBranchMergeTargetCommand extends QuickCommand {
100100
placeholder: 'Pick a merge target branch',
101101
filter: (branch: GitBranch) => branch.remote && branch.name !== state.branch,
102102
resetTitle: 'Reset Merge Target',
103-
resetDescription: `Reset to "${detectedMergeTarget}"`,
103+
resetDescription: detectedMergeTarget ? `Reset to "${detectedMergeTarget}"` : '',
104104
});
105105
if (result === StepResultBreak) {
106106
continue;

src/commands/quickCommand.steps.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -823,7 +823,7 @@ export function* pickOrResetBranchStep<
823823

824824
const resetButton: QuickInputButton = {
825825
iconPath: new ThemeIcon('notebook-revert'),
826-
tooltip: resetDescription,
826+
tooltip: resetDescription || resetTitle,
827827
};
828828
let resetButtonClicked = false;
829829
const step = createPickStep<BranchQuickPickItem>({

0 commit comments

Comments
 (0)