Closed (fixed)
Project:
Web Links
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
27 May 2015 at 07:05 UTC
Updated:
12 Jun 2015 at 19:14 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
jonathan1055 commentedWe have already made a similar fix in weblinks_blocks_form_alter() and need to do the same here. Patch for review.
Comment #2
jonathan1055 commentedComment #3
gstegemann commentedTested and works basically. But ...
Are you really sure? I've deleted the term while it was still assigned to a link. The link does not show up on the Web Links page. Attempting to display the link I got the following error message:
Invalid group requested (287) in function weblinks_get_tree, called from _weblinks_blocks_related_block.I expected that an affected link will be changed to 'Unclassified'. However, that did not happen. I had to edit the link first. Then it appears on the Web Links page again.
Comment #4
gstegemann commentedComment #5
jonathan1055 commentedYes, but you have found a different error, not caused by my change. The problem this patch solves is allowing the term to be deleted, by not processing the unrequired modifications to the form in weblinks_form_alter() which create the fatal error.
If we need to do other processing to react to a term being deleted then there is probably a hook provided by taxonomy module. I have replicated your message, which is caused not when viewing the node with the deleted term, but when editing it. There is something else going on, because the related block is not being shown when I view the node, and no error is produced, but when I edit the node the related block is attempted and causes the error. But it should all be fixable - just need more investigation.
Comment #6
gstegemann commentedUnderstand.
Should I file a new issue regarding the 'related block' problem when a term was deleted?
Comment #7
jonathan1055 commentedYes I think it is worth creating a different issue. If you are happy with the correction in the patch above I can commit this first. The other issue might take longer to resolve.
Comment #8
gstegemann commentedYes, I'm happy with the patch and it can be commited.
Comment #10
jonathan1055 commentedThanks. I've linked to the new issue too.