Ver código fonte

Fixes missing `folder` prop on Repository

- Fixes issue when using folder tokens in `worktrees.defaultLocation`
main
Eric Amodio 1 ano atrás
pai
commit
1c77db5c0a
3 arquivos alterados com 4 adições e 5 exclusões
  1. +3
    -3
      src/env/node/git/localGitProvider.ts
  2. +0
    -1
      src/git/models/repository.ts
  3. +1
    -1
      src/plus/github/githubGitProvider.ts

+ 3
- 3
src/env/node/git/localGitProvider.ts Ver arquivo

@ -503,7 +503,7 @@ export class LocalGitProvider implements GitProvider, Disposable {
this.container,
this.onRepositoryChanged.bind(this),
this.descriptor,
folder,
folder ?? workspace.getWorkspaceFolder(uri),
uri,
root,
suspended ?? !window.state.focused,
@ -514,7 +514,7 @@ export class LocalGitProvider implements GitProvider, Disposable {
this.container,
this.onRepositoryChanged.bind(this),
this.descriptor,
folder,
folder ?? workspace.getWorkspaceFolder(canonicalUri),
canonicalUri,
root,
suspended ?? !window.state.focused,
@ -529,7 +529,7 @@ export class LocalGitProvider implements GitProvider, Disposable {
this.container,
this.onRepositoryChanged.bind(this),
this.descriptor,
folder,
folder ?? workspace.getWorkspaceFolder(uri),
uri,
root,
suspended ?? !window.state.focused,

+ 0
- 1
src/git/models/repository.ts Ver arquivo

@ -226,7 +226,6 @@ export class Repository implements Disposable {
suspended: boolean,
closed: boolean = false,
) {
folder = workspace.getWorkspaceFolder(uri) ?? folder;
if (folder != null) {
if (root) {
this.name = folder.name;

+ 1
- 1
src/plus/github/githubGitProvider.ts Ver arquivo

@ -261,7 +261,7 @@ export class GitHubGitProvider implements GitProvider, Disposable {
this.container,
this.onRepositoryChanged.bind(this),
this.descriptor,
folder,
folder ?? workspace.getWorkspaceFolder(uri),
uri,
root,
suspended ?? !window.state.focused,

Carregando…
Cancelar
Salvar