Needs review
Project:
Abuse
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
31 Mar 2010 at 17:07 UTC
Updated:
4 Jun 2010 at 05:00 UTC
When the abuse module unpublishes a comment via the _abuse_disable function, it does not update the comment statistics for the associated node. This causes comment counts to be inaccurate in the node_comment_statistics DB table. I think this issue could be resolved by calling _comment_update_node_statistics in the _abuse_disable function after changing the status of a comment.
According to the code comments in in comments.module, the _comment_update_node_statistics function "should be called any time a comment is added, deleted, or updated."
Please let me know if I should submit a patch for this.
Comments
Comment #1
buzzman commentedpatch would be gr8, but if u r pressed for time, then just post the code snip - thanks
Comment #2
buzzman commentednevermind, this code should do the trick:
EDITED:
place the above code block in abuse.module in-between these 2 lines:
do test and feedback - thanx