From 6add79143b89faa0e8777c868149a108484116b6 Mon Sep 17 00:00:00 2001 From: Dmytro Kozlov Date: Thu, 26 May 2022 17:24:01 +0300 Subject: [PATCH] removed redundant return (fixed linter) (#2647) * removed redundant return * updated lint package version --- Makefile | 2 +- lib/promscrape/scrapework.go | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 18c28a7f15..9ce315e026 100644 --- a/Makefile +++ b/Makefile @@ -160,7 +160,7 @@ golangci-lint: install-golangci-lint golangci-lint run --exclude '(SA4003|SA1019|SA5011):' -D errcheck -D structcheck --timeout 2m install-golangci-lint: - which golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.46.1 + which golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.46.2 install-wwhrd: which wwhrd || GO111MODULE=off go get github.com/frapposelli/wwhrd diff --git a/lib/promscrape/scrapework.go b/lib/promscrape/scrapework.go index 28434cfbec..2c4b7827c2 100644 --- a/lib/promscrape/scrapework.go +++ b/lib/promscrape/scrapework.go @@ -26,7 +26,7 @@ import ( "github.com/VictoriaMetrics/VictoriaMetrics/lib/proxy" "github.com/VictoriaMetrics/VictoriaMetrics/lib/timerpool" "github.com/VictoriaMetrics/metrics" - xxhash "github.com/cespare/xxhash/v2" + "github.com/cespare/xxhash/v2" ) var ( @@ -377,7 +377,6 @@ func (sw *scrapeWork) scrapeAndLogError(scrapeTimestamp, realTimestamp int64) { logger.Warnf("%s", err) sw.lastErrLogTimestamp = fasttime.UnixTimestamp() sw.errsSuppressedCount = 0 - return } var (