Skip to content

Commit 7f53bc0

Browse files
committed
fix bug in updating packages from git
1 parent 5c4245d commit 7f53bc0

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

stdlib/Pkg/src/Operations.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -423,14 +423,13 @@ function install_git(
423423
GitTools.clone(urls[1], repo_path; isbare=true, header = "[$uuid] $name from $(urls[1])", credentials=creds)
424424
end
425425
git_hash = LibGit2.GitHash(hash.bytes)
426-
for i = 2:length(urls)
426+
for url in urls
427427
try with(LibGit2.GitObject, repo, git_hash) do g
428428
end
429429
break # object was found, we can stop
430430
catch err
431431
err isa LibGit2.GitError && err.code == LibGit2.Error.ENOTFOUND || rethrow(err)
432432
end
433-
url = urls[i]
434433
GitTools.fetch(repo, url, refspecs=refspecs, credentials=creds)
435434
end
436435
tree = try

0 commit comments

Comments
 (0)