Sha256: bd430ab5c6e551461a03c83975a65022b7daebbddf7b1998fa6fc7634bc93564

Contents?: true

Size: 246 Bytes

Versions: 3

Compression:

Stored size: 246 Bytes

Contents

# frozen_string_literal: true

module PerfectAudit
  class Error < StandardError
    attr_reader :code

    def initialize(message, code)
      @code = code
      super(message)
    end

    def to_s
      super + " [#{@code}]"
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
perfect_audit-0.3.2 lib/perfect_audit/error.rb
perfect_audit-0.3.1 lib/perfect_audit/error.rb
perfect_audit-0.3.0 lib/perfect_audit/error.rb