fedibird-fe/app/workers/searchability_update_worker.rb

14 lines
295 B
Ruby
Raw Normal View History

2022-08-23 05:14:23 +00:00
# frozen_string_literal: true
class SearchabilityUpdateWorker
include Sidekiq::Worker
sidekiq_options queue: 'pull', lock: :until_executed
def perform(account_id)
SearchabilityUpdateService.new.call(Account.find(account_id))
rescue ActiveRecord::RecordNotFound
true
end
end