Class: Pageflow::PaperclipProcessors::Vtt
- Inherits:
-
Paperclip::Processor
- Object
- Paperclip::Processor
- Pageflow::PaperclipProcessors::Vtt
- Defined in:
- lib/pageflow/paperclip_processors/vtt.rb
Instance Method Summary collapse
Instance Method Details
#make ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/pageflow/paperclip_processors/vtt.rb', line 7 def make destination = make_tempfile_for(file.path) if File.extname(file.path) =~ /\.srt$/ srt_to_vtt(file.path, destination.path) else FileUtils.cp(file.path, destination.path) end destination end |