const enumTypeDescriptionHeader … // GetOpenAPIDefinitionsWithoutDisabledFeatures wraps a GetOpenAPIDefinitions to revert // any change to the schema that was made by disabled features. func GetOpenAPIDefinitionsWithoutDisabledFeatures(GetOpenAPIDefinitions common.GetOpenAPIDefinitions) common.GetOpenAPIDefinitions { … } // restoreDefinitions restores any changes by disabled features from definition map. func restoreDefinitions(defs map[string]common.OpenAPIDefinition) { … } func pruneEnums(schema *spec.Schema) *spec.Schema { … }