Straight out of the box, merging two or more terms results in the error in the title of this issue.

A simple fix is to wrap the function in a hasField() method, to ensure the getValue() method is running on a field that is present on the Entity in question.

Patch incoming :)

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ChristianSanders created an issue. See original summary.

ChristianSanders’s picture

Works with Alpha1 version of the module - since I can only select 1.x-dev the test will probably fail!

stimalsina’s picture

Here is a slightly modified patch for the Alpha1 version. This allows to return early from the loop if an entity doesn't have a field, otherwise it can error at setValue.

legolasbo’s picture

Status: Active » Needs review

Lets see what testbot thinks about this

legolasbo’s picture

Status: Needs review » Needs work

The patch no longer applies because the functionality in question has been moved to the term_reference_change module in the latest dev version. Please update to the latest dev version and verify if this is still an issue for you then.

legolasbo’s picture

Status: Needs work » Needs review
FileSize
3.04 KB

I've taken the time to write an integration test for this to see if the issue is still present and to prevent it from happening in the future. The test passes locally, so it seems like the issue is no longer present.

legolasbo’s picture

Status: Needs review » Fixed

  • legolasbo committed ca534b0 on 8.x-1.x
    Issue #3024238 by ChristianSanders, legolasbo, stimalsina: undefined...

Status: Fixed » Closed (fixed)

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