Skip to content
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

Add nullability annotations to LazyHeaders.Builder functions #3446

Merged
merged 1 commit into from
Dec 14, 2018

Conversation

r-ralph
Copy link
Contributor

@r-ralph r-ralph commented Dec 7, 2018

Description

Add @NonNull and @Nullable annotations to LazyHeaders.Builder and StringHeaderFactory. When there is a possibility of null, a warning is displayed on the IDE and bug entry can be prevented.

Motivation and Context

StringHeaderFactory doesn't allow null value and LazyHeaders.Builder.addHeader(String key, String value) also doesn't allow null value. However, the user can not know this spec unless they actually read the code.

@stale
Copy link

stale bot commented Dec 14, 2018

This issue has been automatically marked as stale because it has not had activity in the last seven days. It will be closed if no further activity occurs within the next seven days. Thank you for your contributions.

@stale stale bot added the stale label Dec 14, 2018
@sjudd
Copy link
Collaborator

sjudd commented Dec 14, 2018

Thanks!

@stale stale bot removed the stale label Dec 14, 2018
@sjudd sjudd merged commit d6345fb into bumptech:master Dec 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants