Sha256: c7c401b6adb76c837b55b2ec8c62fe63734e7945bae559dbc47b6cbd81a5f7c0

Contents?: true

Size: 489 Bytes

Versions: 2

Compression:

Stored size: 489 Bytes

Contents

# frozen_string_literal: true

module Floe
  class Workflow
    module States
      class Fail < Floe::Workflow::State
        attr_reader :cause, :error

        def initialize(workflow, name, payload)
          super

          @cause = payload["Cause"]
          @error = payload["Error"]
        end

        def run!(input)
          [nil, input]
        end

        def status
          "errored"
        end

        def end?
          true
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
floe-0.3.1 lib/floe/workflow/states/fail.rb
floe-0.3.0 lib/floe/workflow/states/fail.rb