[release-11.2.8] Chore: Bump Go version to 1.23.7 (#101294)
* Chore: Bump Go version to 1.23.7 * Chore: Bump golangci-lint version to match Go version * Chore: Run yarn prettier:write * Chore: Bump godeltaprof to v0.1.8 to fix start-up * Chore: Fix wire updated error fixture * Chore: Fix OpenAPI spec diffs * Chore: Fix new linting errors from Go upgrade
This commit is contained in:
@@ -2,6 +2,7 @@ package plugins
|
||||
|
||||
import (
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io/fs"
|
||||
"os"
|
||||
@@ -90,18 +91,16 @@ func (cr *configReaderImpl) parsePluginConfig(path string, file fs.DirEntry) (*p
|
||||
|
||||
func validateRequiredField(apps []*pluginsAsConfig) error {
|
||||
for i := range apps {
|
||||
var errStrings []string
|
||||
errs := []error{}
|
||||
for index, app := range apps[i].Apps {
|
||||
if app.PluginID == "" {
|
||||
errStrings = append(
|
||||
errStrings,
|
||||
fmt.Sprintf("app item %d in configuration doesn't contain required field type", index+1),
|
||||
)
|
||||
err := fmt.Errorf("app item %d in configuration doesn't contain required field type", index+1)
|
||||
errs = append(errs, err)
|
||||
}
|
||||
}
|
||||
|
||||
if len(errStrings) != 0 {
|
||||
return fmt.Errorf(strings.Join(errStrings, "\n"))
|
||||
if len(errs) != 0 {
|
||||
return errors.Join(errs...)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user