all: upgrade to golangci-lint v1.49.0 (#329)

Fixes #242
This commit is contained in:
Michael McLoughlin
2022-09-05 17:25:03 -07:00
committed by GitHub
parent d76a0f6dd6
commit e788b7675f
9 changed files with 433 additions and 436 deletions

View File

@@ -8,7 +8,6 @@ import (
"errors"
"flag"
"fmt"
"io/ioutil"
"log"
"math"
"net/url"
@@ -84,7 +83,7 @@ func mainerr() (err error) {
// Output.
if *output != "" {
err = ioutil.WriteFile(*output, body, 0o640)
err = os.WriteFile(*output, body, 0o640)
} else {
_, err = os.Stdout.Write(body)
}
@@ -103,7 +102,7 @@ var templates embed.FS
func load() (string, error) {
// Prefer explicit filename, if provided.
if *tmpl != "" {
b, err := ioutil.ReadFile(*tmpl)
b, err := os.ReadFile(*tmpl)
if err != nil {
return "", err
}
@@ -125,7 +124,7 @@ func load() (string, error) {
// include template function.
func include(filename string) (string, error) {
b, err := ioutil.ReadFile(filename)
b, err := os.ReadFile(filename)
if err != nil {
return "", err
}