Skip to content

Inconsistent nullability for String value arguments in ResponseCookie from*() factory methods #35377

@rwinch

Description

@rwinch

The methods ResponseCookie.from(...) and ResponseCookie.fromClientResponse(...) declare non-nullable String value arguments.

However, ResponseCookieBuilder.value(@Nullable String value) and DefaultResponseCookieBuilder(String name, @Nullable String value, boolean lenient) are both marked with @Nullable.

Additionally, ResponseCookie and its superclass HttpCookie allow for a null value (it is turned into an empty String).

Metadata

Metadata

Assignees

Labels

in: webIssues in web modules (web, webmvc, webflux, websocket)type: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions