This appears to be related to the behavior originally suggested in Destroying a spammer does not delete their comments.
It appears to be the same issue raised in When comments are flagged, and the user is destroyed, the flags remain, but this post has specific steps to reproduce the issue.
Here's what happened on one site in the network earlier today:
- A question was posted much earlier
- Someone came along, and as an unregistered, new user with no other activity, posted a spam answer to that question at 04:36:54 UTC
- That same user posted a comment on their own answer with the same spam link at 04:37:31 UTC
- The answer was deleted as spam via community votes at 07:32:07 UTC
- A high-rep user saw the comment and raised a custom flag on it as being spammy at 07:32:54 UTC
- The unregistered user account was destroyed by a moderator at 08:13:10 UTC
- The comment now shows as "deleted by Anonymous" with a deletion time of 08:13:10 UTC
- The flag on the comment remains, but the only options are "Edit" and "Decline"; there is no "Delete" action
That there is no "Delete" action possible on the flag is reasonable, since the comment is now deleted. However, the flag is/was legitimate, so to decline the flag would be wrong. There's also nothing to leave while editing out the spammy part of the comment, as the comment consists solely of the same spam URL.
There is also no undelete option on the comment, so it's not possible to undelete the comment and then mark the flag as helpful by re-deleting the comment.
Effectively, this means that while the comment itself is effectively gone, the flag on it is in limbo and there is no good choice for what to do with the flag.
When deleting comments normally, my understanding is that any flags associated with those comments are automatically marked as helpful. However, it appears that the deletion of comments when destroying the user who posted them does not do that.
Therefore, I suggest that whenever comments are deleted as part of the owning user being destroyed, any pending flags against those comments should be marked as helpful at the same time.
It would also be a nice touch if those comments showed as deleted by Community♦, instead of Anonymous, but that's less of a concern in my case.