The following errors appear on the top of my site:
================================
Deprecated: Array and string offset access syntax with curly braces is deprecated in /.../modules/name/src/NameFormatParser.php on line 127

Deprecated: Array and string offset access syntax with curly braces is deprecated in /.../modules/name/src/NameFormatParser.php on line 128

Deprecated: Array and string offset access syntax with curly braces is deprecated in /.../modules/name/src/NameFormatParser.php on line 289

Deprecated: Array and string offset access syntax with curly braces is deprecated in /.../modules/name/src/NameFormatParser.php on line 347

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Londova created an issue. See original summary.

jaydub’s picture

Note that this deprecation method is for PHP 7.4+. Since Drupal 8 still supports earlier versions of PHP 7 I don't think this is a bug report per se but more of a general cleanup task.

jaydub’s picture

Status: Active » Needs review
FileSize
1.07 KB

Here's a quick and dirty patch.

  • nkoporec committed 7ca45c6 on 8.x-1.x authored by jaydub
    Issue #3125621 by jaydub: Array and string offset access syntax with...
nkoporec’s picture

Status: Needs review » Fixed

Thanks for the patch, I have manually review it and it fixes the deprecation warnings when using PHP 7.4.

nkoporec’s picture

Status: Fixed » Closed (fixed)
ahebrank’s picture

This already is fixed in dev, but here's an updated patch for the stable release that also fixes errors in NameAutocomplete.

Deprecated: Array and string offset access syntax with curly braces is deprecated in /app/web/modules/contrib/name/src/NameAutocomplete.php on line 120

Deprecated: Array and string offset access syntax with curly braces is deprecated in /app/web/modules/contrib/name/src/NameAutocomplete.php on line 121