Skip to content

Commit d2c1d17

Browse files
committed
nit fixes
1 parent 534ab12 commit d2c1d17

File tree

4 files changed

+14
-12
lines changed

4 files changed

+14
-12
lines changed

lib/ActionInputValidator/ValidatorFactory.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -135,13 +135,14 @@ class ValidatorFactory {
135135
}
136136
static isBlessedSitecontainerApp(actionParams) {
137137
return __awaiter(this, void 0, void 0, function* () {
138-
var _a, _b;
138+
var _a;
139139
const appService = new azure_app_service_1.AzureAppService(actionParams.endpoint, actionParams.resourceGroupName, actionParams.appName, actionParams.slotName);
140140
let config = yield appService.getConfiguration();
141141
core.debug(`LinuxFxVersion of app is: ${config.properties.linuxFxVersion}`);
142-
actionParams.blessedAppSitecontainers = (((_a = config.properties.linuxFxVersion) === null || _a === void 0 ? void 0 : _a.startsWith("DOCKER|")) !== true
143-
&& ((_b = config.properties.linuxFxVersion) === null || _b === void 0 ? void 0 : _b.startsWith("COMPOSE|")) !== true
144-
&& config.properties.linuxFxVersion !== "SITECONTAINERS");
142+
const linuxFxVersion = ((_a = config.properties.linuxFxVersion) === null || _a === void 0 ? void 0 : _a.toUpperCase()) || "";
143+
actionParams.blessedAppSitecontainers = (!linuxFxVersion.startsWith("DOCKER|")
144+
&& !linuxFxVersion.startsWith("COMPOSE|")
145+
&& linuxFxVersion !== "SITECONTAINERS");
145146
return actionParams.blessedAppSitecontainers;
146147
});
147148
}

package-lock.json

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"@actions/core": "^1.10.0",
3535
"@actions/github": "^4.0.0",
3636
"actions-secret-parser": "^1.0.4",
37-
"azure-actions-appservice-rest": "^1.3.33",
37+
"azure-actions-appservice-rest": "^1.3.34-test.0.1",
3838
"azure-actions-utility": "^1.0.3",
3939
"azure-actions-webclient": "^1.1.1"
4040
}

src/ActionInputValidator/ValidatorFactory.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,9 +93,10 @@ export class ValidatorFactory {
9393

9494
core.debug(`LinuxFxVersion of app is: ${config.properties.linuxFxVersion}`);
9595

96-
actionParams.blessedAppSitecontainers = (config.properties.linuxFxVersion?.startsWith("DOCKER|") !== true
97-
&& config.properties.linuxFxVersion?.startsWith("COMPOSE|") !== true
98-
&& config.properties.linuxFxVersion !== "SITECONTAINERS");
96+
const linuxFxVersion = config.properties.linuxFxVersion?.toUpperCase() || "";
97+
actionParams.blessedAppSitecontainers = (!linuxFxVersion.startsWith("DOCKER|")
98+
&& !linuxFxVersion.startsWith("COMPOSE|")
99+
&& linuxFxVersion !== "SITECONTAINERS");
99100

100101
return actionParams.blessedAppSitecontainers;
101102
}

0 commit comments

Comments
 (0)