Sha256: e775686416ce2a180dfe4a1b74ffd7acf5b7218a53415b55d4a84643a9ffddb5

Contents?: true

Size: 264 Bytes

Versions: 1

Compression:

Stored size: 264 Bytes

Contents

module Cloudist
  class ErrorCallback < Callback  
    def call(payload)
      @payload = payload
      
      case source.arity
      when 0
        instance_exec(&source)
      when 1
        instance_exec(payload.exception, &source)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
cloudist-0.2.0 lib/cloudist/callbacks/error_callback.rb