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

Fix passing null to strlen #31655

Merged
merged 1 commit into from
Mar 24, 2022
Merged

Fix passing null to strlen #31655

merged 1 commit into from
Mar 24, 2022

Conversation

tcitworld
Copy link
Member

@tcitworld tcitworld commented Mar 22, 2022

$filter can be null as it's the default value passed in ContactsMenuController.

On PHP 8.1:

strlen(): Passing null to parameter #1 ($string) of type string is deprecated

@tcitworld tcitworld added bug 3. to review Waiting for reviews labels Mar 22, 2022
@tcitworld tcitworld added this to the Nextcloud 24 milestone Mar 22, 2022
@tcitworld tcitworld requested review from juliushaertl and a team March 22, 2022 09:28
@tcitworld tcitworld requested review from skjnldsv and come-nc and removed request for a team March 22, 2022 09:28
@come-nc
Copy link
Contributor

come-nc commented Mar 24, 2022

/rebase

$filter can be null as it's the default value passed in
ContactsMenuController.

On PHP 8.1 : strlen(): Passing null to parameter #1 ($string) of type string is deprecated

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
@come-nc come-nc merged commit fbf1334 into master Mar 24, 2022
@come-nc come-nc deleted the fix-passing-null-to-strlen branch March 24, 2022 13:03
@come-nc
Copy link
Contributor

come-nc commented Mar 24, 2022

I guess no backport since 23 is not allowing PHP>8.0?

@come-nc come-nc added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Mar 24, 2022
@tcitworld
Copy link
Member Author

I guess no backport since 23 is not allowing PHP>8.0?

There's no PHP 8.0 specific code here. 🤔 The fusion null operator is here since PHP 7.

@skjnldsv skjnldsv mentioned this pull request Mar 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release Ready to be released and/or waiting for tests to finish bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants