-
-
Notifications
You must be signed in to change notification settings - Fork 6.9k
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
Update validateAttribute for PHP 8.1 #19668
Conversation
In function validateAttribute call_user_func does not control if $value is null Added control to fix
Thank you for putting effort in the improvement of the Yii framework. Unfortunately a use case is missing. It is required to get a better understanding of the pull request and helps us to determine the necessity and applicability of the suggested change to the framework. Could you supply us with a use case please? Please be as detailed as possible and show some code! Thanks! This is an automated comment, triggered by adding the label |
In PHP 8.1 we need to check if argument of a function is not null, when try to generate code with gii throw an error PHP Deprecated Warning – yii\base\ErrorException |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a line for CHANGELOG. Thanks.
@samdark Added to Changelog Thanks |
Thanks. |
Hmm... seems it broke existing tests: d056c7f |
Re-checked and reverted. The error depends on what's in the |
In function validateAttribute call_user_func does not control if $value is null
Added control to fix