- Merge request !14Issue #3257718: PHP 8.1 AddressDefaultFormatter::viewElement deprecation → (Closed) created by hswong3i
On PHP 8.1, when the address default formatter is used if not all the used fields are filled (because they are hidden for example) the following deprecation is triggered:
Deprecated function: htmlspecialchars(): Passing null to parameter #1 ($string) of type string is deprecated in Drupal\Component\Utility\Html::escape() (line 424 of core/lib/Drupal/Component/Utility/Html.php).
We should ensure the field value is not empty before passing the value to Drupal\Component\Utility\Html::escape()
.
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.