I'm using Heartbeat to show activity on the site. When user post comment to the node Heartbeat activity stream shows that comment. But when user delete comment it does not delete it from the Heartbeat activity stream.

How to delete comment also from Heartbeat activity stream? This should be done of course automatically when user delete comment from the node.

Same thing for deleting nodes.

In the Rules there was no Heartbeat log delete possibility.

1 Answer 1


Heartbeat module implemented hook_user_delete() and hook_node_delete() hooks itself. take a look at their implementations.. I think you can implement hook_comment_delete($comment) hook in your module to delete activities from heartbeat_activity table. Here is the documentation.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.