mirror of
https://blitiri.com.ar/repos/chasquid
synced 2026-01-27 20:45:56 +00:00
Replace uses of ioutil
ioutil package was deprecated in Go 1.16, replace all uses with their respective replacements. This patch was generated with a combination of `gofmt -r`, `eg`, and manually (for `ioutil.ReadDir`).
This commit is contained in:
@@ -6,7 +6,6 @@ package config
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
|
||||
"blitiri.com.ar/go/log"
|
||||
@@ -39,7 +38,7 @@ func Load(path, overrides string) (*Config, error) {
|
||||
c := proto.Clone(defaultConfig).(*Config)
|
||||
|
||||
// Load from the path.
|
||||
buf, err := ioutil.ReadFile(path)
|
||||
buf, err := os.ReadFile(path)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to read config at %q: %v", path, err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user