chore(lint): fix issues
- sources/env: remove unused `envToInt` - fix `ireturn` error for `newCipherDESCBCBlock`
This commit is contained in:
@@ -29,6 +29,10 @@ issues:
|
|||||||
- text: "returns interface \\(github\\.com\\/vishvananda\\/netlink\\.Link\\)"
|
- text: "returns interface \\(github\\.com\\/vishvananda\\/netlink\\.Link\\)"
|
||||||
linters:
|
linters:
|
||||||
- ireturn
|
- ireturn
|
||||||
|
- path: "internal\\/openvpn\\/pkcs8\\/descbc\\.go"
|
||||||
|
text: "newCipherDESCBCBlock returns interface \\(github\\.com\\/youmark\\/pkcs8\\.Cipher\\)"
|
||||||
|
linters:
|
||||||
|
- ireturn
|
||||||
|
|
||||||
linters:
|
linters:
|
||||||
enable:
|
enable:
|
||||||
|
|||||||
@@ -29,14 +29,6 @@ func envToCSV(envKey string) (values []string) {
|
|||||||
return lowerAndSplit(csv)
|
return lowerAndSplit(csv)
|
||||||
}
|
}
|
||||||
|
|
||||||
func envToInt(envKey string) (n int, err error) {
|
|
||||||
s := getCleanedEnv(envKey)
|
|
||||||
if s == "" {
|
|
||||||
return 0, nil
|
|
||||||
}
|
|
||||||
return strconv.Atoi(s)
|
|
||||||
}
|
|
||||||
|
|
||||||
func envToFloat64(envKey string) (f float64, err error) {
|
func envToFloat64(envKey string) (f float64, err error) {
|
||||||
s := getCleanedEnv(envKey)
|
s := getCleanedEnv(envKey)
|
||||||
if s == "" {
|
if s == "" {
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ func init() { //nolint:gochecknoinits
|
|||||||
pkcs8lib.RegisterCipher(oidDESCBC, newCipherDESCBCBlock)
|
pkcs8lib.RegisterCipher(oidDESCBC, newCipherDESCBCBlock)
|
||||||
}
|
}
|
||||||
|
|
||||||
func newCipherDESCBCBlock() pkcs8lib.Cipher { //nolint:ireturn
|
func newCipherDESCBCBlock() pkcs8lib.Cipher {
|
||||||
return cipherDESCBC{}
|
return cipherDESCBC{}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user