Skip to content

Commit 06444fa

Browse files
author
audrastump
committed
moved lowercase check to beginning
1 parent 19fb963 commit 06444fa

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

src/actions/deploy.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,10 @@ export async function deploy(
3939

4040
// check manifest stability
4141
core.startGroup('Checking manifest stability')
42-
const resourceType =
42+
const resourceType = (
4343
core.getInput('resource-type') ||
4444
'Microsoft.ContainerService/managedClusters'
45+
).toLowerCase()
4546
const resourceTypes: Resource[] = getResources(
4647
deployedManifestFiles,
4748
models.DEPLOYMENT_TYPES.concat([

src/actions/promote.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,9 +166,10 @@ async function promoteBlueGreen(kubectl: Kubectl, manifests: string[]) {
166166

167167
// checking stability of newly created deployments
168168
core.startGroup('Checking manifest stability')
169-
const resourceType =
169+
const resourceType = (
170170
core.getInput('resource-type') ||
171171
'Microsoft.ContainerService/managedClusters'
172+
).toLowerCase()
172173
const deployedManifestFiles = deployResult.manifestFiles
173174
const resources: Resource[] = getResources(
174175
deployedManifestFiles,

src/utilities/manifestStabilityUtils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export async function checkManifestStability(
1313
resourceType: string
1414
): Promise<void> {
1515
// Skip if resource type is microsoft.containerservice/fleets
16-
if (resourceType.toLowerCase() === 'microsoft.containerservice/fleets') {
16+
if (resourceType === 'microsoft.containerservice/fleets') {
1717
core.info(
1818
'Skipping checkManifestStability for microsoft.containerservice/fleets'
1919
)

0 commit comments

Comments
 (0)