Skip to content

Commit 4b5602d

Browse files
authored
fix(config-resolver): update default value to undefined for dualstack/FIPS config (#1925)
1 parent 2e9c5dc commit 4b5602d

5 files changed

Lines changed: 13 additions & 8 deletions

File tree

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@smithy/config-resolver": patch
3+
---
4+
5+
fix: update default value to undefined for dualstack/fips config

packages/config-resolver/src/endpointsConfig/NodeUseDualstackEndpointConfigOptions.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ describe("NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS", () => {
4545
test(configFileSelector, profileContent, CONFIG_USE_DUALSTACK_ENDPOINT, SelectorType.CONFIG);
4646
});
4747

48-
it("returns false for default", () => {
48+
it("returns undefined for default", () => {
4949
const { default: defaultValue } = NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS;
50-
expect(defaultValue).toEqual(DEFAULT_USE_DUALSTACK_ENDPOINT);
50+
expect(defaultValue).toBeUndefined();
5151
});
5252
});

packages/config-resolver/src/endpointsConfig/NodeUseDualstackEndpointConfigOptions.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ export const DEFAULT_USE_DUALSTACK_ENDPOINT = false;
1717
/**
1818
* @internal
1919
*/
20-
export const NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS: LoadedConfigSelectors<boolean> = {
20+
export const NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS: LoadedConfigSelectors<boolean | undefined> = {
2121
environmentVariableSelector: (env: NodeJS.ProcessEnv) =>
2222
booleanSelector(env, ENV_USE_DUALSTACK_ENDPOINT, SelectorType.ENV),
2323
configFileSelector: (profile) => booleanSelector(profile, CONFIG_USE_DUALSTACK_ENDPOINT, SelectorType.CONFIG),
24-
default: false,
24+
default: undefined,
2525
};

packages/config-resolver/src/endpointsConfig/NodeUseFipsEndpointConfigOptions.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ describe("NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS", () => {
4545
test(configFileSelector, profileContent, CONFIG_USE_FIPS_ENDPOINT, SelectorType.CONFIG);
4646
});
4747

48-
it("returns false for default", () => {
48+
it("returns undefined for default", () => {
4949
const { default: defaultValue } = NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS;
50-
expect(defaultValue).toEqual(DEFAULT_USE_FIPS_ENDPOINT);
50+
expect(defaultValue).toBeUndefined();
5151
});
5252
});

packages/config-resolver/src/endpointsConfig/NodeUseFipsEndpointConfigOptions.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ export const DEFAULT_USE_FIPS_ENDPOINT = false;
1717
/**
1818
* @internal
1919
*/
20-
export const NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS: LoadedConfigSelectors<boolean> = {
20+
export const NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS: LoadedConfigSelectors<boolean | undefined> = {
2121
environmentVariableSelector: (env: NodeJS.ProcessEnv) =>
2222
booleanSelector(env, ENV_USE_FIPS_ENDPOINT, SelectorType.ENV),
2323
configFileSelector: (profile) => booleanSelector(profile, CONFIG_USE_FIPS_ENDPOINT, SelectorType.CONFIG),
24-
default: false,
24+
default: undefined,
2525
};

0 commit comments

Comments
 (0)