diff options
| author | Paul Buetow <paul@buetow.org> | 2023-06-18 12:09:43 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2023-06-18 12:09:43 +0300 |
| commit | 9e63c35bdb3f2a49f60eabb7f7f1ce8e3e7fe6e4 (patch) | |
| tree | 3a0b81d23db9cec370c67f585b70373788926120 /internal/state.go | |
| parent | 1a963283a18f9c3a69c92bf5b424748c9813d6d4 (diff) | |
add vet and lint checking - fix some lint errors
Diffstat (limited to 'internal/state.go')
| -rw-r--r-- | internal/state.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/internal/state.go b/internal/state.go index f23c8a4..f7e03cf 100644 --- a/internal/state.go +++ b/internal/state.go @@ -3,7 +3,7 @@ package internal import ( "encoding/json" "fmt" - "io/ioutil" + "io" "log" "os" "path/filepath" @@ -42,7 +42,7 @@ func readState(conf config) (state, error) { } defer file.Close() - bytes, err := ioutil.ReadAll(file) + bytes, err := io.ReadAll(file) if err != nil { return s, err } @@ -91,7 +91,7 @@ func (s state) persist() error { return err } - return ioutil.WriteFile(s.stateFile, jsonData, os.ModePerm) + return os.WriteFile(s.stateFile, jsonData, os.ModePerm) } func (s state) report(renotify bool) (string, string, bool) { |
