Class: Pageflow::ProcessImageOrTextTrackJob
- Inherits:
-
ApplicationJob
- Object
- ActiveJob::Base
- ApplicationJob
- Pageflow::ProcessImageOrTextTrackJob
- Includes:
- StateMachineJob
- Defined in:
- app/jobs/pageflow/process_image_or_text_track_job.rb
Instance Method Summary collapse
Instance Method Details
#perform_with_result(file, _options) ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'app/jobs/pageflow/process_image_or_text_track_job.rb', line 7 def perform_with_result(file, ) file..reprocess! if file.valid? :ok else (file) :error end rescue ActiveRecord::RecordInvalid, Errno::ENAMETOOLONG (file) :error end |
#reset_invalid_attachment(file) ⇒ Object
22 23 24 25 26 |
# File 'app/jobs/pageflow/process_image_or_text_track_job.rb', line 22 def (file) file_name = file.file_name file. = nil file.file_name = file_name end |