Address singleCaseSwitch errors

Signed-off-by: Evan Lezar <elezar@nvidia.com>
This commit is contained in:
Evan Lezar
2023-08-25 17:34:30 +02:00
parent f8870b31be
commit 2f48ab99c3
4 changed files with 4 additions and 8 deletions

View File

@@ -146,8 +146,7 @@ func (c *configToml) setFlagToKeyValue(setFlag string) (string, interface{}, err
if v == nil {
return key, nil, errInvalidConfigOption
}
switch v.(type) {
case bool:
if _, ok := v.(bool); ok {
if len(setParts) == 1 {
return key, true, nil
}