mb_strtolower(): Passing null to parameter #1 ($string) of type string is deprecated

Created on 24 October 2023, about 1 year ago
Updated 2 August 2024, 4 months ago

Problem/Motivation

Sometimes, when navigating to an end-point, if $path_alias happened to obtain a value of null, it was passed directly through a mb_strtolower php function in Container->pathCheck(), which does not admit null as a first parameter above php v8.1. This printed an error message in the user UI when encountering this issue.

Steps to reproduce

With version 8x-1.6 of Google Tag installed, navigate through to a page with no path alias.

Proposed resolution

Patch attached which checks first whether the alias is null or not, to leave as is or send it as parameter to mb_strtolower.

๐Ÿ’ฌ Support request
Status

Active

Version

1.0

Component

Code

Created by

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.

Production build 0.71.5 2024