From 7a0dbe1a568d0755afc4c1c432fa3ab9e09adff0 Mon Sep 17 00:00:00 2001 From: Shulhan Date: Tue, 26 Mar 2024 16:07:41 +0700 Subject: all: comply with linter recommendations --- Makefile | 7 ++++++- issuer.go | 4 +--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index b0ee6f0..ee9b420 100644 --- a/Makefile +++ b/Makefile @@ -11,9 +11,14 @@ test: .PHONY: lint lint: - -revive ./... -fieldalignment ./... -shadow ./... + -golangci-lint run \ + --presets bugs,metalinter,performance,unused \ + --disable exhaustive \ + --disable musttag \ + --disable bodyclose \ + ./... build: mkdir -p _sys/usr/bin/ diff --git a/issuer.go b/issuer.go index a151cd5..f4343ae 100644 --- a/issuer.go +++ b/issuer.go @@ -60,9 +60,7 @@ func NewIssuer(label, rawConfig string, rsaPrivateKey *rsa.PrivateKey) (issuer * rawConfig = string(vbytes) } - var vals []string - - vals = strings.Split(rawConfig, valueSeparator) + var vals = strings.Split(rawConfig, valueSeparator) if len(vals) < 2 { return nil, fmt.Errorf(`%s: invalid value %q`, logp, rawConfig) } -- cgit v1.3