softwaregravy/lancaster

View on GitHub
app/workers/send_sms_worker.rb

Summary

Maintainability
A
0 mins
Test Coverage
class SendSmsWorker
  include Sidekiq::Worker

  # if something is going wrong, we don't want to send them a message on every retry
  sidekiq_options queue: :sms, retry: 0

  def perform(sms_message_attempt_id)
    attempt = SmsMessageAttempt.find(sms_message_attempt_id)
    attempt.attempt_send
  end
end