Sha256: 8ef884cd11216a11491caabec2775101cdb0559a3652120874b1fc0e1ff5085a

Contents?: true

Size: 376 Bytes

Versions: 19

Compression:

Stored size: 376 Bytes

Contents

module Pageflow
  class ProcessFileJob
    @queue = :resizing

    extend StateMachineJob

    def self.perform_with_result(file, _options)
      file.processed_attachment = file.unprocessed_attachment
      file.save!

      :ok
    rescue ActiveRecord::RecordInvalid, Errno::ENAMETOOLONG
      file.processed_attachment = nil
      file.save!
      :error
    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
pageflow-12.6.0 app/jobs/pageflow/process_file_job.rb
pageflow-12.5.0 app/jobs/pageflow/process_file_job.rb
pageflow-12.4.1 app/jobs/pageflow/process_file_job.rb
pageflow-12.4.0 app/jobs/pageflow/process_file_job.rb
pageflow-12.3.0 app/jobs/pageflow/process_file_job.rb
pageflow-12.2.0 app/jobs/pageflow/process_file_job.rb
pageflow-12.1.0 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.4 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.3 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.2 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.1 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0.rc7 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0.rc6 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0.rc5 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0.rc4 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0.rc3 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0.rc2 app/jobs/pageflow/process_file_job.rb
pageflow-12.0.0.rc1 app/jobs/pageflow/process_file_job.rb