Skip to content

Commit e219157

Browse files
committed
Fix Default Region ENV check.
1 parent b182ab6 commit e219157

File tree

4 files changed

+16
-5
lines changed

4 files changed

+16
-5
lines changed

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,13 @@
1+
# Keep A Changelog!
2+
3+
See this http://keepachangelog.com link for information on how we want this documented formatted.
4+
5+
## 1.0.7
6+
7+
### Fixed
8+
9+
- Crashes with no AWS region environment variable set. Fixes #1.
10+
111
## 1.0.0
212

313
## [1.0.0] - 2023-06-12

package-lock.json

Lines changed: 3 additions & 3 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
@@ -1,6 +1,6 @@
11
{
22
"name": "lambda-console-cli",
3-
"version": "1.0.6",
3+
"version": "1.0.7",
44
"description": "A CLI to run shell commands or interact with your application on Lambda.",
55
"main": "index.js",
66
"type": "module",

src/regions.mjs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ class Regions {
88
static DEFAULTS = ["us-east-1", "us-east-2", "us-west-1", "us-west-2"];
99

1010
constructor() {
11-
this.default = process.env.AWS_REGION || process.env.AWS_DEFAULT_REGION;
11+
this.default =
12+
process.env.AWS_REGION || process.env.AWS_DEFAULT_REGION || "us-east-1";
1213
this.spinner = createSpinner("Loading Regions...");
1314
}
1415

0 commit comments

Comments
 (0)