class PandaProcessor
Public Instance Methods
make()
click to toggle source
# File lib/panda-processor.rb, line 2 def make begin Tinify.key = Rails.application.secrets.panda_api_key source = Tinify.from_file(File.expand_path(file.path)) source.to_file(File.expand_path(file.path)) file rescue Tinify::AccountError, Tinify::ServerError, Tinify::ConnectionError => e puts 'CUSTOM TinifyError: ' + e.message file rescue => e Rollbar.error(e) file end end