Fix multiple workers for the same scheduled status being queueable (#9875)

This commit is contained in:
Eugen Rochko 2019-01-20 12:57:05 +01:00 提交者 GitHub
父節點 6b91da97bb
當前提交 31e7940de5
沒有發現已知的金鑰在資料庫的簽署中
GPG 金鑰 ID: 4AEE18F83AFDEB23
共有 1 個檔案被更改,包括 2 行新增0 行删除

查看文件

@ -3,6 +3,8 @@
class PublishScheduledStatusWorker
include Sidekiq::Worker
sidekiq_options unique: :until_executed
def perform(scheduled_status_id)
scheduled_status = ScheduledStatus.find(scheduled_status_id)
scheduled_status.destroy!