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

bccomp(): bcmath function argument is not well-formed #345

Open
dfrancesch opened this issue Aug 4, 2021 · 1 comment
Open

bccomp(): bcmath function argument is not well-formed #345

dfrancesch opened this issue Aug 4, 2021 · 1 comment
Assignees
Labels

Comments

@dfrancesch
Copy link

Hi!
I'm getting this error in vlucas\valitron\src\Valitron\Validator.php line 366 On Windows.

I think it's an issue with php version 7.4.18 (win), because on php 7.3.29 (linux) it doesn't happen.

@willemwollebrants
Copy link
Collaborator

I've done a bit of reading and you're idea seems correct: https://www.php.net/manual/en/migration74.incompatible.php
"BCMath functions will now warn if a non well-formed number is passed, such as "32foo". The argument will be interpreted as zero, as before."
I think we need to make sure the number is well-formed before passing it to bcmath

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants