Skip to content

Commit 5f7ca90

Browse files
committed
chore: enable unlambda rule from go-critic
Signed-off-by: Matthieu MOREL <[email protected]>
1 parent 9b78552 commit 5f7ca90

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

.golangci.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ linters:
1616
enable-all: true
1717
disabled-checks:
1818
- hugeParam
19-
- unlambda
2019
- unnamedResult
2120
revive:
2221
rules:

config/config.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -361,9 +361,7 @@ func (re *Regexp) UnmarshalYAML(unmarshal func(interface{}) error) error {
361361
}
362362

363363
func substituteEnvVariables(value string) (string, error) {
364-
result := os.Expand(value, func(s string) string {
365-
return os.Getenv(s)
366-
})
364+
result := os.Expand(value, os.Getenv)
367365
if result == "" {
368366
return "", errors.New(value + " environment variable not found")
369367
}

0 commit comments

Comments
 (0)