~cytrogen/masto-fe

ref: e2f58c8c82d66040490a70db2ce9fb8f49d02a8f masto-fe/app/workers/trigger_webhook_worker.rb -rw-r--r-- 267 bytes
e2f58c8c — dependabot[bot] Bump capybara from 3.38.0 to 3.39.0 (#24395) 3 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
# frozen_string_literal: true

class TriggerWebhookWorker
  include Sidekiq::Worker

  def perform(event, class_name, id)
    object = class_name.constantize.find(id)
    WebhookService.new.call(event, object)
  rescue ActiveRecord::RecordNotFound
    true
  end
end