From 7e72509c6bfe9cf4893df1076c52ff8b4ca6a2cc Mon Sep 17 00:00:00 2001 From: Akshaya M Date: Thu, 19 Mar 2020 11:38:04 +0530 Subject: [PATCH] changes in main --- lib/main.js | 2 +- src/main.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/main.js b/lib/main.js index ba89d83d..4948a2a9 100644 --- a/lib/main.js +++ b/lib/main.js @@ -40,7 +40,7 @@ function main() { let servicePrincipalKey = secrets.getSecret("$.clientSecret", true); let tenantId = secrets.getSecret("$.tenantId", false); let subscriptionId = secrets.getSecret("$.subscriptionId", false); - const enablePSSession = !!core.getInput('enable-PSSession'); + const enablePSSession = core.getInput('enable-PSSession').toLowerCase() === "true"; if (!servicePrincipalId || !servicePrincipalKey || !tenantId || !subscriptionId) { throw new Error("Not all values are present in the creds object. Ensure clientId, clientSecret, tenantId and subscriptionId are supplied."); } diff --git a/src/main.ts b/src/main.ts index f81f26d7..86b0ad00 100644 --- a/src/main.ts +++ b/src/main.ts @@ -26,7 +26,7 @@ async function main() { let servicePrincipalKey = secrets.getSecret("$.clientSecret", true); let tenantId = secrets.getSecret("$.tenantId", false); let subscriptionId = secrets.getSecret("$.subscriptionId", false); - const enablePSSession = !!core.getInput('enable-PSSession'); + const enablePSSession = core.getInput('enable-PSSession').toLowerCase() === "true"; if (!servicePrincipalId || !servicePrincipalKey || !tenantId || !subscriptionId) { throw new Error("Not all values are present in the creds object. Ensure clientId, clientSecret, tenantId and subscriptionId are supplied."); }