Updated

app/jobs / close_petitions_early_job.rb

A
13 lines of codes
2 methods
3.6 complexity/method
1 churn
7.1 complexity
0 duplications
class ClosePetitionsEarlyJob < ApplicationJob
  1. ClosePetitionsEarlyJob has no descriptive comment
queue_as :high_priority class << self def schedule_for(time) set(wait_until: time).perform_later(time.iso8601) end end def perform(time)
  1. ClosePetitionsEarlyJob#perform doesn't depend on instance state (maybe move it to another class?)
Petition.close_petitions_early!(time.in_time_zone) end end