For example, take a look at this:
Now, if you click on the question, you will find, that it was deleted. However, the flag still remains. Is this a bug or is this intended to let the flag simply age away?
For example, take a look at this:
Now, if you click on the question, you will find, that it was deleted. However, the flag still remains. Is this a bug or is this intended to let the flag simply age away?
This behavior is by-design. Custom moderator flags should not be automatically dismissed when the post with which they are associated is deleted. Custom moderator flags also never age away. They are all looked at and handled by a human moderator.
Unlike most flags, which serve only to request deletion of a post for a particular reason (indicated by the name/type of the flag), custom moderator flags can bring anything to a moderator's attention and may require some action other than deleting the post. So, just because the post is deleted doesn't mean that the custom moderator flag requires no moderator attention.
Even in this case, just because the post has been deleted doesn't mean that the vandalism doesn't need to be rolled back, and it doesn't mean that a moderator doesn't need to take additional follow-up action, such as messaging the user about vandalism of their own posts.
Posters have deleted and then immediately undeleted their posts before. If that dismissed all the flags then they could keep doing that and avoid the consequences of those flags. Worse than that, if the person flagging spotted what was going on, they wouldn't be able to flag that post in that way again.
Spam would be harder to get rid of if the spammers found out that method would keep their spam round longer. Same with vandalism.