-
Notifications
You must be signed in to change notification settings - Fork 612
fix(packages): maintain singleton config object #6959
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
7c7bac3
to
0b7c699
Compare
e84ade3
to
3dcd29f
Compare
f8bc334
to
9e28d8a
Compare
endpointDiscoveryEnabled !== undefined | ||
? () => Promise.resolve(endpointDiscoveryEnabled) | ||
: endpointDiscoveryEnabledProvider, | ||
isClientEndpointDiscoveryEnabled: endpointDiscoveryEnabled !== undefined, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this boolean seems wrong... what if endpointDiscoveryEnabled === false
?
not related to this PR though
export const resolveTokenConfig = <T>(input: T & TokenInputConfig): T & TokenResolvedConfig => { | ||
const { token } = input; | ||
return Object.assign(input, { | ||
token: token ? normalizeTokenProvider(token) : tokenDefaultProvider(input as any), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this fallback makes no sense to me since input
has no overlap with FromSsoInit
, the type of the falsy branch.
9e28d8a
to
4249188
Compare
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread. |
Related to smithy-lang/smithy-typescript#1550
This change makes all config resolvers mutate the input config instead of creating a shallow copy. The shallow copies, if preserved by references, can result in reading inconsistent config data.