mirror of
https://github.com/caddyserver/caddy.git
synced 2026-01-16 17:20:34 +00:00
chore: make the linter happier (#3245)
* chore: make the linter happier * chore: remove reference to maligned linter in .golangci.yml
This commit is contained in:
committed by
GitHub
parent
28fdf64dc5
commit
7dfd69cdc5
@@ -210,7 +210,7 @@ func GetModules(scope string) []ModuleInfo {
|
||||
var mods []ModuleInfo
|
||||
iterateModules:
|
||||
for id, m := range modules {
|
||||
modParts := strings.Split(string(id), ".")
|
||||
modParts := strings.Split(id, ".")
|
||||
|
||||
// match only the next level of nesting
|
||||
if len(modParts) != len(scopeParts)+1 {
|
||||
@@ -241,9 +241,9 @@ func Modules() []string {
|
||||
modulesMu.RLock()
|
||||
defer modulesMu.RUnlock()
|
||||
|
||||
var names []string
|
||||
names := make([]string, 0, len(modules))
|
||||
for name := range modules {
|
||||
names = append(names, string(name))
|
||||
names = append(names, name)
|
||||
}
|
||||
|
||||
sort.Strings(names)
|
||||
|
||||
Reference in New Issue
Block a user