-
Notifications
You must be signed in to change notification settings - Fork 193
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
Make required context parameters required #2964
Conversation
A new generated diff is ready to view.
A new doc preview is ready to view. |
5d76520
to
38c137b
Compare
A new generated diff is ready to view.
A new doc preview is ready to view. |
A new generated diff is ready to view.
A new doc preview is ready to view. |
64840e7
to
b403adf
Compare
A new generated diff is ready to view.
A new doc preview is ready to view. |
if let Some(field) = field { | ||
if field.as_ref() != "" { | ||
return Some(field) | ||
} | ||
} | ||
None |
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.
I think this can be one line:
if let Some(field) = field { | |
if field.as_ref() != "" { | |
return Some(field) | |
} | |
} | |
None | |
field.map(AsRef::as_ref).filter(|s| s != "") |
e473125
to
de61ad7
Compare
A new generated diff is ready to view.
A new doc preview is ready to view. |
Motivation and Context
When a
@contextParam
is marked as required, we will enforce it on inputs. Since these fields may influence endpoint, omitting them can result in a different target being hit.Description
Testing
Checklist
CHANGELOG.next.toml
if I made changes to the smithy-rs codegen or runtime cratesCHANGELOG.next.toml
if I made changes to the AWS SDK, generated SDK code, or SDK runtime cratesBy submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.