Skip to content

Commit

Permalink
remove unused function
Browse files Browse the repository at this point in the history
  • Loading branch information
nullfunc committed Jan 13, 2025
1 parent 7c6466f commit 3033298
Showing 1 changed file with 0 additions and 31 deletions.
31 changes: 0 additions & 31 deletions src/pkg/cli/compose/loader.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,37 +79,6 @@ func (c *Loader) LoadProjectName(ctx context.Context) (string, error) {
return project.Name, nil
}

func (c *Loader) LoadProjectWithoutValidation(ctx context.Context) (*Project, error) {
if c.cached != nil {
return c.cached, nil
}
// Set logrus send logs via the term package
termLogger := logs.TermLogFormatter{Term: term.DefaultTerm}
logrus.SetFormatter(termLogger)

projOpts, err := c.newProjectOptions()
if err != nil {
return nil, err
}

project, err := projOpts.LoadProject(ctx)
if err != nil {
if errors.Is(err, errdefs.ErrNotFound) {
return nil, types.ErrComposeFileNotFound
}

return nil, err
}

if term.DoDebug() {
b, _ := yaml.Marshal(project)
fmt.Println(string(b))
}

c.cached = project
return project, nil
}

func (c *Loader) LoadProjectOptions(ctx context.Context) (*cli.ProjectOptions, error) {
// Set logrus send logs via the term package
termLogger := logs.TermLogFormatter{Term: term.DefaultTerm}
Expand Down

0 comments on commit 3033298

Please sign in to comment.