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

[8.x] Align PHP 8.1 behavior of e() #36262

Merged
merged 1 commit into from
Feb 15, 2021
Merged

Commits on Feb 14, 2021

  1. Align PHP 8.1 behavior

    While not explicitly allowed in the PHPDoc, `e(null)` returns `""` with PHP < 8.1
    On PHP >= 8.1, an error is thrown if `null` is passed to `htmlspecialchars`.
    
    As `e(null)` is still a common case (for instance via Blade in view templates) I think it's safest to just default the `null` value to an empty string to get the same behavior with the next PHP minor version.
    kylekatarnls authored Feb 14, 2021
    Configuration menu
    Copy the full SHA
    90e5fab View commit details
    Browse the repository at this point in the history