It returns warning

Warning: Creating default object from empty value in Drupal\field_collection\Entity\FieldCollectionItem->createDuplicate() (line 211 of /srv/modules/field_collection/src/Entity/FieldCollectionItem.php).

if this method exists and works perfect for me without it.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

id.tarzanych created an issue. See original summary.

id.tarzanych’s picture

Status: Active » Needs review
FileSize
715 bytes

Attaching patch that worked for me

  • jmuzz committed 168b1b5 on 8.x-1.x authored by id.tarzanych
    Issue #2768161 by id.tarzanych: Remove unnecessary override of...
jmuzz’s picture

Status: Needs review » Fixed

You're right, the functionality it was trying to implement is covered by the overridden method.

Thanks for the patch.

Status: Fixed » Closed (fixed)

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