func addModelType(models map[string]*ControllerModels) error {
	changes := false
	for _, cm := range models {
		for name, m := range cm.Models {
			if m.ModelType == "" {
				changes = true
				m.ModelType = model.IAAS
				cm.Models[name] = m
			}
		}
	}
	if changes {
		return WriteModelsFile(models)
	}
	return nil
}
// addModelType adds missing model type data if necessary.
addModelType adds missing model type data if necessary.
// addModelType adds missing model type data if necessary .
func addModelType(models map[string]*ControllerModels) error {
	changes := false
	for _, cm := range models {
		for name, m := range cm.Models {
			if m.ModelType == "" {
				changes = true
				m.ModelType = model.IAAS
				cm.Models[name] = m
			}
		}
	}
	if changes {
		return WriteModelsFile(models)
	}
	return nil
}
func addModelType ( models map [ string ] * ControllerModels ) error { changes := false for _ , cm := range models { for name , m := range cm . Models { if m . ModelType == " " { changes = true m . ModelType = model . IAAS cm . Models [ name ] = m } } } if changes { return WriteModelsFile ( models ) } return nil }
addModelType adds missing model type data if necessary.
addModelType adds missing model type data if necessary .