From 5d3da238a1e558aaed1360bf48ec0f5e9e59cdf8 Mon Sep 17 00:00:00 2001 From: Benjamin Christopher Simmonds <44439583+benibenj@users.noreply.github.com> Date: Wed, 11 Mar 2026 21:26:54 +0100 Subject: [PATCH] Apply suggestion from @Copilot Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- extensions/git/src/repository.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/extensions/git/src/repository.ts b/extensions/git/src/repository.ts index ac0b2bff402..446384bc3db 100644 --- a/extensions/git/src/repository.ts +++ b/extensions/git/src/repository.ts @@ -1899,9 +1899,8 @@ export class Repository implements Disposable { } private async _setupWorktree(worktreePath: string): Promise { - // Copy worktree include files. We explicitly do not await this - // since we don't want to block the worktree creation on the - // copy operation. + // Copy worktree include files and wait for the copy to complete + // before running any worktree-created tasks. await this._copyWorktreeIncludeFiles(worktreePath); await this._runWorktreeCreatedTasks(worktreePath);