- π¦πΉAustria alexh
Just had the same issue when upgrading to PHP 8.1 and the patch solved the issue. Thanks!
When using PHP 8.1, if the image has no title ($image['title'] is NULL) the following error is displayed:
Deprecated function: mb_strlen(): Passing null to parameter #1 ($string) of type string is deprecated in drupal_strlen() (line 485 of /var/www/html/includes/unicode.inc).
This is because theme_cs_adaptive_image_formatter has this code:
if (drupal_strlen($item['title']) > 0) {
$image['title'] = $item['title'];
}
That passes NULL to drupal_strlen(), which leads to the following:
return mb_strlen($text);
That's where the error is thrown.
Don't call drupal_strlen() if $image['title'] is empty.
Provide a patch.
n/a
n/a
n/a
Needs review
1.0
Code
The issue particularly affects sites running on PHP version 8.1.0 or later.
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
Just had the same issue when upgrading to PHP 8.1 and the patch solved the issue. Thanks!