IsUsed checks whether a configuration namespace in the extension namespaces list is used in the user-provided configuration
(userConfigs map[string]string)
| 428 | // IsUsed checks whether a configuration namespace in the extension namespaces list |
| 429 | // is used in the user-provided configuration |
| 430 | func (e ManagedExtension) IsUsed(userConfigs map[string]string) bool { |
| 431 | for k := range userConfigs { |
| 432 | for _, namespace := range e.Namespaces { |
| 433 | if strings.HasPrefix(k, namespace+".") { |
| 434 | return true |
| 435 | } |
| 436 | } |
| 437 | } |
| 438 | return false |
| 439 | } |
| 440 | |
| 441 | // IsManagedExtensionUsed checks whether a configuration namespace in the named extension namespaces list |
| 442 | // is used in the user-provided configuration |
no outgoing calls
no test coverage detected