Bump linter to 1.47 (#9218)

*bump linter to 1.47

Co-authored-by: William Banfield <4561443+williambanfield@users.noreply.github.com>
This commit is contained in:
samricotta
2022-08-11 15:53:17 +02:00
committed by GitHub
co-authored by William Banfield
parent fbd754b4de
commit dad439f115
49 changed files with 92 additions and 94 deletions
+1 -1
View File
@@ -72,7 +72,7 @@ func (s *SnapshotStore) saveMetadata() error {
// save the file to a new file and move it to make saving atomic.
newFile := filepath.Join(s.dir, "metadata.json.new")
file := filepath.Join(s.dir, "metadata.json")
err = ioutil.WriteFile(newFile, bz, 0644) // nolint: gosec
err = ioutil.WriteFile(newFile, bz, 0644) //nolint: gosec
if err != nil {
return err
}
+1 -1
View File
@@ -1,4 +1,4 @@
// nolint: gosec
//nolint: gosec
package main
import (
+1 -1
View File
@@ -1,4 +1,4 @@
// nolint: gosec
//nolint: gosec
package addr
import (
+1 -1
View File
@@ -1,4 +1,4 @@
// nolint: gosec
//nolint: gosec
package main
import (
+1 -1
View File
@@ -1,4 +1,4 @@
// nolint: gosec
//nolint: gosec
package main
import (
@@ -1,4 +1,4 @@
// nolint: gosec
//nolint: gosec
package main
import (
+1 -1
View File
@@ -1779,7 +1779,7 @@ func (cs *State) tryAddVote(vote *types.Vote, peerID p2p.ID) (bool, error) {
// If the vote height is off, we'll just ignore it,
// But if it's a conflicting sig, add it to the cs.evpool.
// If it's otherwise invalid, punish peer.
// nolint: gocritic
//nolint: gocritic
if voteErr, ok := err.(*types.ErrVoteConflictingVotes); ok {
if cs.privValidatorPubKey == nil {
return false, errPubKeyIsNotSet
+1 -1
View File
@@ -7,7 +7,7 @@ import (
"fmt"
"net"
"net/http"
_ "net/http/pprof" // nolint: gosec // securely exposed on separate, optional port
_ "net/http/pprof" //nolint: gosec // securely exposed on separate, optional port
"strconv"
"strings"
"time"