Class: Spraycan::Image

Inherits:
Bottle::Foreman
  • Object
show all
Defined in:
lib/spraycan/workers/image.rb

Instance Method Summary collapse

Instance Method Details

#process(payload) ⇒ Object



3
4
5
6
7
8
9
# File 'lib/spraycan/workers/image.rb', line 3

def process(payload)
  return failure("Image payload expected a hash, got #{payload.class.to_s}.") unless payload.is_a?(Hash)
  success({})
rescue => e
  Bugsnag.notify(e)
  failure("Fatal error handling image: #{e.message}")
end