Post Destroyed Webhook Event

I was able to track down the cause of this issue. The webhook I am using depends on a specific tag.

The issue appears to be in lib/post_destroyer.rb. tag_ids is not set on delete webhook events like it is when going through enqueue_post_hooks on the WebHook class. After making the following change, my destroy events started working correctly.

I replaced

    WebHook.enqueue_hooks(:post, :post_destroyed,
      id: @post.id,
      category_id: @post&.topic&.category_id,
      payload: payload
    ) if WebHook.active_web_hooks(:post).exists?

with

    WebHook.enqueue_hooks(:post, :post_destroyed,
      id: @post.id,
      category_id: @post&.topic&.category_id,
      tag_ids: @post&.topic&.tags&.pluck(:id),
      payload: payload
    ) if WebHook.active_web_hooks(:post).exists?