fix: use new RecipeMeta struct
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
f4d8b45859
commit
8aaedee39e
|
@ -82,18 +82,18 @@ var appNewCommand = &cli.Command{
|
|||
}
|
||||
|
||||
// getRecipe retrieves a recipe from the recipe catalogue.
|
||||
func getRecipe(recipeName string) (catalogue.Recipe, error) {
|
||||
func getRecipe(recipeName string) (catalogue.RecipeMeta, error) {
|
||||
catl, err := catalogue.ReadRecipeCatalogue()
|
||||
if err != nil {
|
||||
return catalogue.Recipe{}, err
|
||||
return catalogue.RecipeMeta{}, err
|
||||
}
|
||||
|
||||
rec, ok := catl[recipeName]
|
||||
if !ok {
|
||||
return catalogue.Recipe{}, fmt.Errorf("recipe '%s' does not exist?", recipeName)
|
||||
return catalogue.RecipeMeta{}, fmt.Errorf("recipe '%s' does not exist?", recipeName)
|
||||
}
|
||||
if err := recipe.EnsureExists(rec.Name); err != nil {
|
||||
return catalogue.Recipe{}, err
|
||||
return catalogue.RecipeMeta{}, err
|
||||
}
|
||||
|
||||
return rec, nil
|
||||
|
|
Loading…
Reference in New Issue