Issue: I receive the following error when adding an existing (and already added) node after having added a new node:

Notice: Undefined variable: attach_entity in inline_entity_form_reference_form_validate() (line 1151 of /this/is/my/sitepath/sites/all/modules/inline_entity_form/inline_entity_form.module).

This is on IEF version 7.x-1.5 with 1872316-ief-bundle-selection-erv-22_0.patch applied. Drupal core 7.34

I can recreate the issue by doing the following:

  1. Create a parent content type and a child content type, and add a few nodes to each
  2. Create an entity relationship from the parent to the child content type, set to use IEF. In my case I'm using an entity relationship view to filter the child nodes, using the mentioned patch to limit the bundle types.
  3. Use IEF to add two existing child nodes (eg: "A" and "B") to a parent node ("X")
  4. Add a new node ("C") to parent node "X".
  5. Try to add "A" or "B" to "X" again
  6. This error results

The error does not display without the "new" node added, I've attached screenshots for both states. I have not yet tried other combinations or quantities, but I have recreated the issue three separate times. This issue came up during alpha/regression testing. It is unlikely to come up in our production UI, but I wanted to document it.

Comments

jweirather’s picture

Issue summary: View changes
mstef’s picture

Version: 7.x-1.5 » 7.x-1.6
Status: Active » Needs review
StatusFileSize
new624 bytes
bojanz’s picture

That unset is definitely odd.

  • bojanz committed c1f5b47 on 7.x-1.x authored by mstef
    Issue #2419019 by mstef, bojanz: Error adding existing node after...
bojanz’s picture

Status: Needs review » Fixed

Committed the fix, thanks.

Status: Fixed » Closed (fixed)

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