Sha256: 1db6446957985ce67f6937090637c1a5949717eaffbe01db3d061cc095d4e996

Contents?: true

Size: 311 Bytes

Versions: 9

Compression:

Stored size: 311 Bytes

Contents

# frozen_string_literal: true

# Incase you need to throw an error related to steppy
class SteppyError < StandardError
  attr_reader :steppy

  def initialize(steppy = nil)
    if steppy
      @steppy = steppy
      message = steppy.is_a?(String) ? steppy : steppy.to_json
    end

    super(message)
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
steppy-1.0.8 lib/steppy/error.rb
steppy-1.0.7 lib/steppy/error.rb
steppy-1.0.6 lib/steppy/error.rb
steppy-1.0.5 lib/steppy/error.rb
steppy-1.0.4 lib/steppy/error.rb
steppy-1.0.3 lib/steppy/error.rb
steppy-1.0.2 lib/steppy/error.rb
steppy-1.0.1 lib/steppy/error.rb
steppy-1.0.0 lib/steppy/error.rb