Skip to content

Commit

Permalink
don't shadow err
Browse files Browse the repository at this point in the history
  • Loading branch information
mohammed90 authored Dec 14, 2023
1 parent af15836 commit d89d150
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions environment.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,8 @@ func (b Builder) newEnvironment(ctx context.Context) (*environment, error) {
return nil, fmt.Errorf("embed directory does not exist: %s", d.Dir)
}
log.Printf("[INFO] Embedding directory: %s", d.Dir)

var buf bytes.Buffer
tpl, err := template.New("embed").Parse(embeddedModuleTemplate)
buf.Reset()
tpl, err = template.New("embed").Parse(embeddedModuleTemplate)
if err != nil {
return nil, err
}
Expand Down

0 comments on commit d89d150

Please sign in to comment.