After upgrading Drupal Core from 8.7.10 to 8.8.1 I am now getting multiple error messages that appear to be related to this module. I am using PHP version 7.3.9. These are the error messages that are displayed after the cache is cleared:

Notice: Undefined offset: 0 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 103 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Notice: Undefined offset: 0 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 104 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Notice: Undefined offset: 1 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 103 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Notice: Undefined offset: 1 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 104 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Notice: Undefined offset: 2 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 103 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Notice: Undefined offset: 2 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 104 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Notice: Undefined offset: 3 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 103 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Notice: Undefined offset: 3 in Drupal\element_class_formatter\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter->viewElements() (line 104 of C:\xampp\htdocs\...\modules\contrib\element_class_formatter\src\Plugin\Field\FieldFormatter\EntityReferenceLabelClassFormatter.php). array(31)

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

frmcclurg created an issue. See original summary.

Asterovim’s picture

Same problem with 8.8.2 and php 7.3

apaderno’s picture

Version: 8.x-1.0 » 8.x-1.x-dev
larowlan’s picture

Status: Active » Needs review
FileSize
2.55 KB
3.35 KB

At first I thought this was a security issue, but in testing revealed that the filtered out items are emitted as empty elements, so all good.

larowlan’s picture

Priority: Major » Normal

Warnings aren't major, adjusting priority

The last submitted patch, 4: 3106661-fail.patch, failed testing. View results

rikki_iki’s picture

Status: Needs review » Reviewed & tested by the community

  • rikki_iki committed 517962a on 8.x-1.x authored by larowlan
    Issue #3106661 by larowlan: "Notice: Undefined offset" errors after...
rikki_iki’s picture

Status: Reviewed & tested by the community » Fixed

Thanks for the fix larowlan

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.