First, this module is great, thank you. I specifically needed this module for the update action. The action works as advertised and saved me a lot of time.

There is one issue, however. When the update action adds ancestor terms on an entity, it doesn't appear to check that the term already exists before making the addition. Or perhaps it's the case that if there are two terms that have a common ancestor, it is adding that term twice. For example, say a node currently has a child term and its parent term. They have a common ancestor -- for the child term it is a grandparent; for the parent term, it's a parent. It may be adding the common ancestor term twice. I'm not sure.

What I do know is that after used the update action on a set of nodes, I used the Devel module to inspect the values in my taxonomy reference field on the nodes and there were, in some cases, multiple instances of the same tid. It seems like somewhere in the module code a check needs to be made or some deduplication should be performed.

CommentFileSizeAuthor
#4 taxonomy_set_lineage-3466027-4.patch1.51 KBdshields
Command icon Show commands

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

aaronpinero created an issue. See original summary.

igorbiki made their first commit to this issue’s fork.

dshields’s picture

Status: Active » Needs review
StatusFileSize
new1.51 KB

Please consider this: making the same change on the initial save as well as the update.

akoepke made their first commit to this issue’s fork.

akoepke’s picture

Status: Needs review » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

  • akoepke committed f124f22f on 2.0.x
    feat: #3466027 Update Taxonomy Term Parents action creates duplicates...
akoepke’s picture

Just added changes from patch file from @dshields

This got missed because it was not part of the merge request. Anyone can get access to issue branches. This allows you to commit changes and create updated merge requests.

That way all changes are located in one spot.

Status: Fixed » Closed (fixed)

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