Closed (duplicate)
Project:
Webform
Version:
6.3.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
28 Aug 2026 at 14:28 UTC
Updated:
6 Oct 2026 at 13:50 UTC
Jump to comment: Most recent
On PHP 8.5 deprecation warning is triggered in Drupal\webform\Element\WebformHtmlEditor
Deprecated function: Using null as an array offset is deprecated, use an empty string instead in Drupal\webform\Element\WebformHtmlEditor::processTextFormat() (line 304 of /var/www/html/web/modules/contrib/webform/src/Element/WebformHtmlEditor.php).
$element['format']['format']['#default_value'] could have a NULL value.
Using NULL as an array offset is deprecated in newer PHP versions.
Add condition isset( $element['format']['format']['#default_value']) on line 304
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
yaqbick commentedComment #4
alorencIn my case, the field's stored filter format wasn't included in its #allowed_formats list, so TextFormat::processFormat() in core deliberately sets #default_value to NULL to force an admin to select a valid format.
The patch adds an isset($element['format']['format']['#default_value']) guard.
Comment #5
alorencComment #7
liam morlandFixed as part of #3590360: Make tests pass on PHP 8.5.