Upgrade go version to 1.18 (#5045)
* Upgrade go version to 1.18 * fix go 1.18 compatibility * update gofmt * ignore golangci-lint staticcheck * update gofmt
This commit is contained in:
@@ -538,6 +538,7 @@ func (mo monitoringOperator) GetAppWorkloads(ns string, apps []string) map[strin
|
||||
for _, appObj := range applicationList {
|
||||
if appFilter(appObj) {
|
||||
for _, com := range appObj.Status.ComponentList.Objects {
|
||||
//nolint:staticcheck // TODO Use golang.org/x/text/cases instead.
|
||||
kind := strings.Title(com.Kind)
|
||||
name := com.Name
|
||||
componentsMap[getAppFullName((appObj))] = append(componentsMap[getAppFullName(appObj)], kind+":"+name)
|
||||
|
||||
@@ -942,6 +942,7 @@ func (t *tenantOperator) isAppComponent(ns, kind, componentName string) (bool, s
|
||||
|
||||
for appName, cList := range appWorkloads {
|
||||
for _, component := range cList {
|
||||
//nolint:staticcheck // TODO Use golang.org/x/text/cases instead.
|
||||
if component == fmt.Sprintf("%s:%s", strings.Title(kind), componentName) {
|
||||
return true, appName
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user