Commit 915172e9 authored by Matthew Holt's avatar Matthew Holt

templates: Close files after done including them

parent 4d066b7e
...@@ -28,6 +28,7 @@ func (c context) Include(filename string) (string, error) { ...@@ -28,6 +28,7 @@ func (c context) Include(filename string) (string, error) {
if err != nil { if err != nil {
return "", err return "", err
} }
defer file.Close()
body, err := ioutil.ReadAll(file) body, err := ioutil.ReadAll(file)
if err != nil { if err != nil {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment