Skip to content

fix(http): prevent NPE by non-null controller parameters#12495

Merged
kesselb merged 1 commit intomainfrom
fix/http/controller-non-null-params
Mar 9, 2026
Merged

fix(http): prevent NPE by non-null controller parameters#12495
kesselb merged 1 commit intomainfrom
fix/http/controller-non-null-params

Conversation

@ChristophWurst
Copy link
Member

Some controller params were nullable but only in the controller method and not the method passed into. This can lead to a NPE when the param is actually missing from a HTTP request.

For #11224

* @param string $smtpUser
* @param string $smtpPassword
* @param string|null $imapPassword
* @param string|null $smtpPassword
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could also drop the param phpdoc as they don't provide any additional information to the type hints.

Signed-off-by: Christoph Wurst <1374172+ChristophWurst@users.noreply.github.com>
@ChristophWurst ChristophWurst force-pushed the fix/http/controller-non-null-params branch from 9c82d58 to 8ab9849 Compare March 9, 2026 16:20
@kesselb kesselb merged commit 3ebb95a into main Mar 9, 2026
42 checks passed
@kesselb kesselb deleted the fix/http/controller-non-null-params branch March 9, 2026 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants