Update go version, modules and remove ioutil

This commit is contained in:
Ricardo Katz 2021-08-06 11:18:17 -03:00
parent 6f0401fc73
commit d226d831bd
31 changed files with 576 additions and 288 deletions

View file

@ -24,7 +24,6 @@ import (
"encoding/json"
"fmt"
"io"
"io/ioutil"
"math/rand" // #nosec
"net"
"net/url"
@ -76,7 +75,7 @@ type Template struct {
//NewTemplate returns a new Template instance or an
//error if the specified template file contains errors
func NewTemplate(file string) (*Template, error) {
data, err := ioutil.ReadFile(file)
data, err := os.ReadFile(file)
if err != nil {
return nil, errors.Wrapf(err, "unexpected error reading template %v", file)
}