// CheckAndSetDefaults validates the config and sets defaults.
CheckAndSetDefaults validates the config and sets defaults.
// CheckAndSetDefaults validates the config and sets defaults .
func (c *OpenEBSConfig) CheckAndSetDefaults() error {
	if c.Client == nil {
		return trace.BadParameter("missing Kubernetes client")
	}
	if c.Namespace == "" {
		c.Namespace = defaults.OpenEBSNamespace
	}
	if c.ConfigMapName == "" {
		c.ConfigMapName = constants.OpenEBSNDMConfigMap
	}
	if c.DaemonSetName == "" {
		c.DaemonSetName = constants.OpenEBSNDMDaemonSet
	}
	return nil
}
func ( c * OpenEBSConfig ) CheckAndSetDefaults ( ) error { if c . Client == nil { return trace . BadParameter ( " " ) } if c . Namespace == " " { c . Namespace = defaults . OpenEBSNamespace } if c . ConfigMapName == " " { c . ConfigMapName = constants . OpenEBSNDMConfigMap } if c . DaemonSetName == " " { c . DaemonSetName = constants . OpenEBSNDMDaemonSet } return nil }
CheckAndSetDefaults validates the config and sets defaults.
CheckAndSetDefaults validates the config and sets defaults .