Skip to content

Commit

Permalink
Fix build failure and trigger pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
snehapar9 committed Sep 24, 2023
1 parent bcfd2d5 commit 76c506d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4926,7 +4926,7 @@ var ContainerAppHelper = /** @class */ (function () {
return [4 /*yield*/, new Utility_1.Utility().executeAndthrowIfError("az", args)];
case 2:
executionResult = _a.sent();
return [2 /*return*/, !executionResult.stderr ? executionResult.stdout.toLowerCase().replace(/["() ]/g, "") : "eastus2"];
return [2 /*return*/, !executionResult.stderr ? executionResult.stdout.toLowerCase().replace(/["() ]/g, "").trim() : "eastus2"];
case 3:
err_9 = _a.sent();
core.warning(err_9.message);
Expand Down Expand Up @@ -5013,7 +5013,7 @@ var ContainerAppHelper = /** @class */ (function () {
_a.trys.push([1, 3, , 4]);
args = ["containerapp", "env", "create", "-n", "" + name, "-g", "" + resourceGroup];
if (!util.isNullOrEmpty(location)) {
args.push("-l", "northcentralusstage");
args.push("-l", "" + location);
}
return [4 /*yield*/, exec.exec("az", args)];
case 2:
Expand Down
4 changes: 2 additions & 2 deletions src/ContainerAppHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ export class ContainerAppHelper {
try {
let args = [`provider`, `show`, `-n`, `Microsoft.App`, `--query`, `resourceTypes[?resourceType=='containerApps'].locations[] | [0]`];
const executionResult = await new Utility().executeAndthrowIfError(`az`, args);
return !executionResult.stderr ? executionResult.stdout.toLowerCase().replace(/["() ]/g, ``) : `eastus2`;
return !executionResult.stderr ? executionResult.stdout.toLowerCase().replace(/["() ]/g, "").trim() : `eastus2`;
} catch (err) {
core.warning(err.message);
return `eastus2`;
Expand Down Expand Up @@ -267,7 +267,7 @@ export class ContainerAppHelper {
try {
let args = [`containerapp`, `env`, `create`, `-n`, `${name}`, `-g`, `${resourceGroup}`];
if (!util.isNullOrEmpty(location)) {
args.push(`-l`, `northcentralusstage`);
args.push(`-l`, `${location}`);
}
await exec.exec(`az`, args);
} catch (err) {
Expand Down

0 comments on commit 76c506d

Please sign in to comment.