app/models/print.rb
def update_active
      Printer.active.find_each do |printer|
        statuses_by_job_number = driver_class(printer).statuses(printer)
        printer.prints.active.find_each do |print|
          if status = statuses_by_job_number[print.job_number]
            print.update!(status: status)
          end
        end
      end
    end
# Updates status of active print jobs.
Updates status of active print jobs.
Updates status of active print jobs .
def update_active
      Printer.active.find_each do |printer|
        statuses_by_job_number = driver_class(printer).statuses(printer)
        printer.prints.active.find_each do |print|
          if status = statuses_by_job_number[print.job_number]
            print.update!(status: status)
          end
        end
      end
    end
def update_active Printer . active . find_each do | printer | statuses_by_job_number = driver_class ( printer ) . statuses ( printer ) printer . prints . active . find_each do | print | if status = statuses_by_job_number [ print . job_number ] print . update! ( status : status ) end end end end
Updates status of active print jobs.
Updates status of active print jobs .