Class: DragonflyPdf::Processors::RemovePassword

Inherits:
Object
  • Object
show all
Defined in:
lib/dragonfly_pdf/processors/remove_password.rb

Instance Method Summary collapse

Instance Method Details

#call(content, _options = {}) ⇒ Object



4
5
6
7
8
# File 'lib/dragonfly_pdf/processors/remove_password.rb', line 4

def call(content, _options = {})
  content.shell_update(ext: :pdf) do |old_path, new_path|
    "#{gs_command} -q -sOutputFile=#{new_path} -c .setpdfwrite -f #{old_path}"
  end
end