Skip to content

Commit

Permalink
cmd/gaiad/cmd: replace deprecated ioutil with os.WriteFile (backport #…
Browse files Browse the repository at this point in the history
…1660) (#1661)

* cmd/gaiad/cmd: replace deprecated ioutil with os.WriteFile (#1660)

Fixes a problem reported by the linters that ioutil.WriteFile
is deprecated hence we should use os.WriteFile.

(cherry picked from commit 6ac473a)

# Conflicts:
#	cmd/gaiad/cmd/testnet.go

* Mergify mangled the code with git markers - removed those

Co-authored-by: Emmanuel T Odeke <[email protected]>
Co-authored-by: Milan Mulji <[email protected]>
  • Loading branch information
3 people authored Aug 10, 2022
1 parent d0884c2 commit b118baa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/gaiad/cmd/testnet.go
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ func writeFile(name string, dir string, contents []byte) error {
return err
}

err = tmos.WriteFile(file, contents, 0o644)
err = os.WriteFile(file, contents, 0o600)
if err != nil {
return err
}
Expand Down

0 comments on commit b118baa

Please sign in to comment.