Problem/Motivation

PHP 8.1 built-in string functions will trigger a deprecation error when a NULL is passed in. Sometime we do this when getting something from the server variables.

Steps to reproduce

See test runs in #3220021: [meta] Ensure compatibility of Drupal 9 with PHP 8.1 (as it evolves)

Proposed resolution

Provide a better default value - ie. an empty string.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

CommentFileSizeAuthor
#2 3239285-2.patch1.92 KBalexpott

Comments

alexpott created an issue. See original summary.

alexpott’s picture

Status: Active » Needs review
StatusFileSize
new1.92 KB
daffie’s picture

Status: Needs review » Reviewed & tested by the community

Looks good to me.

larowlan’s picture

Status: Reviewed & tested by the community » Fixed

Committed 1052cac and pushed to 9.3.x. Thanks!

  • larowlan committed 1052cac on 9.3.x
    Issue #3239285 by alexpott: Passing request headers to string functions...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.