Skip to content

Commit

Permalink
Merge pull request #216 from evanstoner/fix-resource-casing
Browse files Browse the repository at this point in the history
fix: resources capitalization in spec
  • Loading branch information
carlosmmatos authored Sep 24, 2024
2 parents 0045ee3 + aa4ab2c commit ef11c1f
Show file tree
Hide file tree
Showing 15 changed files with 30 additions and 28 deletions.
2 changes: 2 additions & 0 deletions specs/transformation.sed
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
# ensure ASPM name is consistent with other abbreviations e.g. AspmApi not ASPMApi
s/"ASPM"/"aspm"/g
# multiple schemas mistakenly capitalize the resources parameter PLATFORMPG-778983
s/"Resources"/"resources"/g
4 changes: 2 additions & 2 deletions src/models/AlertsContainerAlertsCountValue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function AlertsContainerAlertsCountValueFromJSONTyped(json: any, ignoreDi
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
resources: (json["resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function AlertsContainerAlertsCountValueToJSON(value?: AlertsContainerAle
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/CommonCountResponse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function CommonCountResponseFromJSONTyped(json: any, ignoreDiscriminator:
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
resources: (json["resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function CommonCountResponseToJSON(value?: CommonCountResponse | null): a
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/DetectionsApiAssessmentDetections.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function DetectionsApiAssessmentDetectionsFromJSONTyped(json: any, ignore
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIAssessmentDetectionsFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIAssessmentDetectionsFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function DetectionsApiAssessmentDetectionsToJSON(value?: DetectionsApiAss
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIAssessmentDetectionsToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIAssessmentDetectionsToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/DetectionsApiCombinedDetections.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function DetectionsApiCombinedDetectionsFromJSONTyped(json: any, ignoreDi
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPICombinedDetectionsFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPICombinedDetectionsFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function DetectionsApiCombinedDetectionsToJSON(value?: DetectionsApiCombi
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPICombinedDetectionsToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPICombinedDetectionsToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/DetectionsApiDetectionsCount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function DetectionsApiDetectionsCountFromJSONTyped(json: any, ignoreDiscr
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIDetectionCountFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIDetectionCountFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function DetectionsApiDetectionsCountToJSON(value?: DetectionsApiDetectio
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIDetectionCountToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIDetectionCountToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/DriftindicatorsDriftIndicatorsCountValue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function DriftindicatorsDriftIndicatorsCountValueFromJSONTyped(json: any,
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
resources: (json["resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function DriftindicatorsDriftIndicatorsCountValueToJSON(value?: Driftindi
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/DriftindicatorsDriftIndicatorsFieldValue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function DriftindicatorsDriftIndicatorsFieldValueFromJSONTyped(json: any,
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIFilterResponseFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIFilterResponseFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function DriftindicatorsDriftIndicatorsFieldValueToJSON(value?: Driftindi
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIFilterResponseToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIFilterResponseToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/K8siomsKubernetesIOMCountValue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function K8siomsKubernetesIOMCountValueFromJSONTyped(json: any, ignoreDis
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
resources: (json["resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function K8siomsKubernetesIOMCountValueToJSON(value?: K8siomsKubernetesIO
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/K8siomsKubernetesIOMFieldValue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function K8siomsKubernetesIOMFieldValueFromJSONTyped(json: any, ignoreDis
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIFilterResponseFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIFilterResponseFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function K8siomsKubernetesIOMFieldValueToJSON(value?: K8siomsKubernetesIO
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIFilterResponseToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIFilterResponseToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/ModelsPolicyEntityResponse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function ModelsPolicyEntityResponseFromJSONTyped(json: any, ignoreDiscrim
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIPolicyEntityFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIPolicyEntityFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function ModelsPolicyEntityResponseToJSON(value?: ModelsPolicyEntityRespo
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIPolicyEntityToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIPolicyEntityToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/ModelsPolicyExclusionEntityResponse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function ModelsPolicyExclusionEntityResponseFromJSONTyped(json: any, igno
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIPolicyExclusionFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIPolicyExclusionFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function ModelsPolicyExclusionEntityResponseToJSON(value?: ModelsPolicyEx
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIPolicyExclusionToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIPolicyExclusionToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/ModelsPolicyGroupEntityResponse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function ModelsPolicyGroupEntityResponseFromJSONTyped(json: any, ignoreDi
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIPolicyGroupFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIPolicyGroupFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function ModelsPolicyGroupEntityResponseToJSON(value?: ModelsPolicyGroupE
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIPolicyGroupToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIPolicyGroupToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
4 changes: 2 additions & 2 deletions src/models/PackagesApiPackagesByVulnCount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function PackagesApiPackagesByVulnCountFromJSONTyped(json: any, ignoreDis
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(ModelsAPIPackagesByVulnCountFromJSON),
resources: (json["resources"] as Array<any>).map(ModelsAPIPackagesByVulnCountFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function PackagesApiPackagesByVulnCountToJSON(value?: PackagesApiPackages
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(ModelsAPIPackagesByVulnCountToJSON),
resources: (value["resources"] as Array<any>).map(ModelsAPIPackagesByVulnCountToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export function UnidentifiedcontainersUnidentifiedContainersCountValueFromJSONTy
return json;
}
return {
resources: (json["Resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
resources: (json["resources"] as Array<any>).map(CommonCountAsResourceFromJSON),
errors: json["errors"] == null ? undefined : (json["errors"] as Array<any>).map(MsaAPIErrorFromJSON),
meta: MsaMetaInfoFromJSON(json["meta"]),
};
Expand All @@ -75,7 +75,7 @@ export function UnidentifiedcontainersUnidentifiedContainersCountValueToJSON(val
return value;
}
return {
Resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
resources: (value["resources"] as Array<any>).map(CommonCountAsResourceToJSON),
errors: value["errors"] == null ? undefined : (value["errors"] as Array<any>).map(MsaAPIErrorToJSON),
meta: MsaMetaInfoToJSON(value["meta"]),
};
Expand Down

0 comments on commit ef11c1f

Please sign in to comment.