Skip to content

QA - mb_http_input - function returns FALSE for type 'L' or 'l' #9018

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

Closed

Conversation

juan-morales
Copy link
Contributor

Information

Extension: mbstring
Function: mb_http_input
Case: Parameter $type is 'L' or 'l' is provided and function returns false

Another reason to test this is that in the code there is a //TODO note on this case, suggesting that there might be a possibility that in the future instead of FALSE ... empty string might be returned ... is an open question developer left there.

I think is wort the effort to have a test on this, but is just my opinion.

Code coverage

Before
image

After
image

@cmb69
Copy link
Member

cmb69 commented Jul 15, 2022

Yeah, I think it makes sense to test this condition. @alexdowad, what do you think.

BTW, the underlying mbstring.http_input and friends have been deprecated long ago, but have still not been removed. Either we remove the settings with PHP 9, or we should undeprecate.

@juan-morales
Copy link
Contributor Author

juan-morales commented Jul 15, 2022

Yeah, I think it makes sense to test this condition. @alexdowad, what do you think.

BTW, the underlying mbstring.http_input and friends have been deprecated long ago, but have still not been removed. Either we remove the settings with PHP 9, or we should undeprecate.

I Am open to do What is needed on this change.

Thanks for the review and I stay tune on the conversation if any modification is needed

@alexdowad
Copy link
Contributor

Yeah, I think it makes sense to test this condition. @alexdowad, what do you think.

BTW, the underlying mbstring.http_input and friends have been deprecated long ago, but have still not been removed. Either we remove the settings with PHP 9, or we should undeprecate.

I suggest that:

  • The TODO note in the code should be deleted. It has doubtless been there for many years, without anything changing.
  • A test should be added, confirming the existing behavior, as @juan-morales suggests.
  • We should schedule when to delete the deprecated functionality.

@cmb69 cmb69 closed this in 30d89b1 Jul 15, 2022
cmb69 added a commit that referenced this pull request Jul 15, 2022
@cmb69
Copy link
Member

cmb69 commented Jul 15, 2022

Thank you!

I have deleted the TODO comment now.

@alexdowad
Copy link
Contributor

When should this functionality be removed? At the next major version bump?

@cmb69
Copy link
Member

cmb69 commented Jul 15, 2022

@alexdowad, yes (if we really want to remove it; see https://externals.io/message/103087).

@juan-morales
Copy link
Contributor Author

thanks @cmb69 and @alexdowad for the support

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.

3 participants