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:
Mohammed Al Sahaf
2020-04-09 00:31:51 +03:00
committed by GitHub
parent 28fdf64dc5
commit 7dfd69cdc5
19 changed files with 28 additions and 26 deletions

View File

@@ -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)