Skip to content

Commit

Permalink
Do not fetch all refs (#7797)
Browse files Browse the repository at this point in the history
Which would unnecessarily slow down the pull compare operation.
  • Loading branch information
typeless authored and lafriks committed Aug 13, 2019
1 parent c662f4c commit 602155d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/git/repo_compare.go
Expand Up @@ -54,7 +54,7 @@ func (repo *Repository) GetCompareInfo(basePath, baseBranch, headBranch string)
if repo.Path != basePath {
// Add a temporary remote
tmpRemote = strconv.FormatInt(time.Now().UnixNano(), 10)
if err = repo.AddRemote(tmpRemote, basePath, true); err != nil {
if err = repo.AddRemote(tmpRemote, basePath, false); err != nil {
return nil, fmt.Errorf("AddRemote: %v", err)
}
defer func() {
Expand Down

0 comments on commit 602155d

Please sign in to comment.