Skip to content

Commit 0f77136

Browse files
committed
'nolint:gomnd' -> 'nolint:mnd'.
1 parent cab6ff8 commit 0f77136

File tree

7 files changed

+10
-10
lines changed

7 files changed

+10
-10
lines changed

aws_config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ func GetAwsConfig(ctx context.Context, c *Config) (context.Context, aws.Config,
8989
staticCreds bool
9090
)
9191
if c.AccessKey != "" || c.SecretKey != "" || c.Token != "" {
92-
params := make([]string, 0, 3) //nolint:gomnd
92+
params := make([]string, 0, 3) //nolint:mnd
9393
if c.AccessKey != "" {
9494
params = append(params, "access key")
9595
}

configtesting/config.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ sso_registration_scopes = sso:account:access
152152

153153
defer os.Remove(file.Name())
154154

155-
err = os.WriteFile(file.Name(), []byte(tc.SharedConfigurationFile), 0600) //nolint:gomnd
155+
err = os.WriteFile(file.Name(), []byte(tc.SharedConfigurationFile), 0600) //nolint:mnd
156156

157157
if err != nil {
158158
t.Fatalf("unexpected error writing shared configuration file: %s", err)
@@ -259,7 +259,7 @@ region = us-east-1
259259

260260
defer os.Remove(file.Name())
261261

262-
err = os.WriteFile(file.Name(), []byte(tc.SharedConfigurationFile), 0600) //nolint:gomnd
262+
err = os.WriteFile(file.Name(), []byte(tc.SharedConfigurationFile), 0600) //nolint:mnd
263263

264264
if err != nil {
265265
t.Fatalf("unexpected error writing shared configuration file: %s", err)

configtesting/file_parsing.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ sso_start_url = https://d-123456789a.awsapps.com/start#
152152

153153
defer os.Remove(file.Name())
154154

155-
err = os.WriteFile(file.Name(), []byte(tc.SharedConfigurationFile), 0600) //nolint:gomnd
155+
err = os.WriteFile(file.Name(), []byte(tc.SharedConfigurationFile), 0600) //nolint:mnd
156156

157157
if err != nil {
158158
t.Fatalf("unexpected error writing shared configuration file: %s", err)

logging/hc_logger.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ func flattenFields(fields ...map[string]any) []any {
5353
for _, m := range fields {
5454
totalLen = len(m)
5555
}
56-
f := make([]any, 0, totalLen*2) //nolint:gomnd
56+
f := make([]any, 0, totalLen*2) //nolint:mnd
5757

5858
for _, m := range fields {
5959
for k, v := range m {

logging/http.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -230,8 +230,8 @@ func normalizeHeaderName(k string) string {
230230
}
231231

232232
func authorizationHeaderAttribute(v string) (attribute.KeyValue, bool) {
233-
parts := regexp.MustCompile(`\s+`).Split(v, 2) //nolint:gomnd
234-
if len(parts) != 2 { //nolint:gomnd
233+
parts := regexp.MustCompile(`\s+`).Split(v, 2) //nolint:mnd
234+
if len(parts) != 2 { //nolint:mnd
235235
return attribute.KeyValue{}, false
236236
}
237237
scheme := parts[0]
@@ -271,7 +271,7 @@ func authorizationHeaderAttribute(v string) (attribute.KeyValue, bool) {
271271
func resendCountAttribute(v string) (kv attribute.KeyValue, ok bool) {
272272
re := regexp.MustCompile(`attempt=(\d+);`)
273273
match := re.FindStringSubmatch(v)
274-
if len(match) != 2 { //nolint:gomnd
274+
if len(match) != 2 { //nolint:mnd
275275
return
276276
}
277277

servicemocks/mock.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -488,7 +488,7 @@ func SsoCredentialsApiMock() (func(), string) {
488488
w.Write([]byte(fmt.Sprintf( //nolint:errcheck
489489
ssoCredentialsResponse,
490490
time.Now().
491-
Add(15*time.Minute). //nolint:gomnd
491+
Add(15*time.Minute). //nolint:mnd
492492
UnixNano()/int64(time.Millisecond))))
493493
}))
494494

servicemocks/setup.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ func SsoTestSetup(t *testing.T, ssoKey string) (err error) {
199199
}()
200200

201201
_, err = tokenFile.WriteString(fmt.Sprintf(ssoTokenCacheFile, time.Now().
202-
Add(15*time.Minute). //nolint:gomnd
202+
Add(15*time.Minute). //nolint:mnd
203203
Format(time.RFC3339)))
204204
if err != nil {
205205
return err

0 commit comments

Comments
 (0)