Skip to content

Commit

Permalink
Close file
Browse files Browse the repository at this point in the history
  • Loading branch information
CallanTaylor committed Nov 11, 2019
1 parent 12cc53d commit 8affab1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions assets/assets.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ func ReadFile(file string) (content string, err error) {
if err != nil {
return content, err
}
defer file.Close()
buf, err := ioutil.ReadAll(file)
if err != nil {
return content, err
Expand All @@ -65,6 +66,7 @@ func ReadFile(file string) (content string, err error) {
if err != nil {
return content, err
}
defer file.Close()
buf, err := ioutil.ReadAll(file)
if err != nil {
return content, err
Expand Down

0 comments on commit 8affab1

Please sign in to comment.