Skip to content

Commit

Permalink
fix: make depDownloader in KpmClient public
Browse files Browse the repository at this point in the history
Signed-off-by: zongz <zongzhe1024@163.com>
  • Loading branch information
zong-zhe committed Apr 26, 2024
1 parent 2037685 commit b229c74
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ type KpmClient struct {
// The writer of the log.
logWriter io.Writer
// The downloader of the dependencies.
depDownloader *downloader.DepDownloader
DepDownloader *downloader.DepDownloader
// The home path of kpm for global configuration file and kcl package storage path.
homePath string
// The settings of kpm loaded from the global configuration file.
Expand All @@ -62,7 +62,7 @@ func NewKpmClient() (*KpmClient, error) {
logWriter: os.Stdout,
settings: *settings,
homePath: homePath,
depDownloader: &downloader.DepDownloader{},
DepDownloader: &downloader.DepDownloader{},
}, nil
}

Expand Down Expand Up @@ -849,7 +849,7 @@ func (c *KpmClient) Download(dep *pkg.Dependency, homePath, localPath string) (*
}

if dep.Source.Oci != nil {
err := c.depDownloader.Download(*downloader.NewDownloadOptions(
err := c.DepDownloader.Download(*downloader.NewDownloadOptions(
downloader.WithLocalPath(localPath),
downloader.WithSource(dep.Source),
downloader.WithLogWriter(c.logWriter),
Expand Down

0 comments on commit b229c74

Please sign in to comment.