Skip to content

Commit 927f63e

Browse files
committed
Fixes ensures branch slicing is by selected HEAD
1 parent b733a22 commit 927f63e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/webviews/plus/timeline/timelineWebview.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -750,7 +750,11 @@ export class TimelineWebviewProvider implements WebviewProvider<State, State, Ti
750750

751751
if (config.showAllBranches && config.sliceBy === 'branch' && scope.type !== 'repo' && !repo.virtual) {
752752
const shas = new Set<string>(
753-
await repo.git.commits().getLogShas?.('^HEAD', { all: true, pathOrUri: scope.uri, limit: 0 }),
753+
await repo.git.commits().getLogShas?.(`^${scope.head?.ref ?? 'HEAD'}`, {
754+
all: true,
755+
pathOrUri: scope.uri,
756+
limit: 0,
757+
}),
754758
);
755759

756760
const commitsUnreachableFromHEAD = dataset.filter(d => shas.has(d.sha));

0 commit comments

Comments
 (0)