Skip to content

Commit

Permalink
Refactor: Rename method
Browse files Browse the repository at this point in the history
Clean-ups before increasing complexity.
  • Loading branch information
isimluk committed Sep 5, 2020
1 parent 9d26339 commit e1b9140
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion metaschema/generate.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func Generate(metaschemaDir, goModule, outputDir string) error {
return err
}

if err := template.GenerateTypes(meta, outputDir); err != nil {
if err := template.GenerateAll(meta, outputDir); err != nil {
return err
}
}
Expand Down
4 changes: 4 additions & 0 deletions metaschema/template/template.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ import (
"github.com/markbates/pkger"
)

func GenerateAll(metaschema *parser.Metaschema, outputDir string) error {
return GenerateTypes(metaschema, outputDir)
}

func GenerateTypes(metaschema *parser.Metaschema, outputDir string) error {
t, err := newTemplate(outputDir)
if err != nil {
Expand Down

0 comments on commit e1b9140

Please sign in to comment.