Module: Paperdragon::File::Process
- Included in:
- Paperdragon::File
- Defined in:
- lib/paperdragon/file/operations.rb
Overview
DISCUSS: allow the metadata passing here or not?
Instance Method Summary collapse
Instance Method Details
#process!(file, new_uid = nil, metadata = {}) {|job| ... } ⇒ Object
5 6 7 8 9 10 11 12 13 14 |
# File 'lib/paperdragon/file/operations.rb', line 5 def process!(file, new_uid=nil, ={}) job = Dragonfly.app.new_job(file) yield job if block_given? old_uid = uid uid!(new_uid) if new_uid # set new uid if this is a replace. upload!(job, old_uid, new_uid, ) end |