Deprecated function: rawurlencode(): Passing null to parameter #1

Created on 16 August 2022, about 2 years ago
Updated 7 July 2023, about 1 year ago

Problem/Motivation

Drupal log showing deprecation warnings when upgraded to PHP8.1.

Deprecated function: rawurlencode(): Passing null to parameter #1 ($string) of type string is deprecated in Drupal\Core\Routing\UrlGenerator->generateFromRoute() (line 306 of /opt/drupal/web/core/lib/Drupal/Core/Routing/UrlGenerator.php).

Steps to reproduce

Proposed resolution

in calls to rawurlencode(), change rawurlencode($string) to rawurlencode($string??'') so that the null coalesce changes null into an empty string.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

πŸ› Bug report
Status

Closed: outdated

Version

9.5

Component
RoutingΒ  β†’

Last updated 8 days ago

Created by

πŸ‡ΊπŸ‡ΈUnited States kwfinken Lansing, MI

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡³πŸ‡ΏNew Zealand quietone New Zealand

    @kwfinken, did you resolve this? How so? Did you determine which contrib module was the cause?

    Since we need more information to move forward with this issue, I am keeping the status to Postponed (maintainer needs more info). If we don't receive additional information to help with the issue, it may be closed after three months.

    Thanks!

  • Status changed to Closed: outdated about 1 year ago
  • πŸ‡ΊπŸ‡ΈUnited States kwfinken Lansing, MI

    This appears to have been resolved by a subsequent core update. I apologize for not having followed the issue and marking it appropriately.

Production build 0.71.5 2024