If an entity use a term reference field, and you later delete a taxonomy term in use by a specific entity, text formatter chokes when trying to resolve the term. (Unfortunately, deleting a term doesn't remove the term references in the relevant fields tables - core bug: http://drupal.org/node/1281114 )

A quick glance lline 480 (where the reported error occurs) leads me to believe that the else statement on line 479 can be changed to:

elseif (isset($terms[$item['tid']]->name)) {

Thoughts?

CommentFileSizeAuthor
#1 1809182.patch738 bytesdamiankloip
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

damiankloip’s picture

Version: 7.x-1.3 » 7.x-1.x-dev
FileSize
738 bytes

Thanks for posting this issue. I think we encountered the same problem today. I think you are right about the related issue. We are trying to use a term that hasn't been loaded.

Here is a patch that hopefully will fix your issue too, which I will probably commit. Can you test and let me know?

damiankloip’s picture

Status: Active » Needs review
damiankloip’s picture

Status: Needs review » Fixed

Committed, http://drupalcode.org/project/textformatter.git/commitdiff/5b58523.

If this doesn't fix your issue, please feel free to re open this.

DannyPfeiffer’s picture

Awesome, that was the fastest response I've ever seen by a maintainer!

damiankloip’s picture

Haha, well I do try.... :)

Status: Fixed » Closed (fixed)

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