Remove redundant check on depth
This commit is contained in:
parent
ab1826f523
commit
16bb936db7
|
@ -109,10 +109,7 @@ func Get(ctx context.Context, opts GetOptions) error {
|
||||||
cloneOpts := &git.CloneOptions{
|
cloneOpts := &git.CloneOptions{
|
||||||
URL: src.String(),
|
URL: src.String(),
|
||||||
Progress: os.Stderr,
|
Progress: os.Stderr,
|
||||||
}
|
Depth: depth,
|
||||||
|
|
||||||
if depth != 0 {
|
|
||||||
cloneOpts.Depth = depth
|
|
||||||
}
|
}
|
||||||
|
|
||||||
repo, err := git.PlainCloneContext(ctx, dstDir, false, cloneOpts)
|
repo, err := git.PlainCloneContext(ctx, dstDir, false, cloneOpts)
|
||||||
|
|
Loading…
Reference in New Issue