Sha256: 78f6db7e4497de1da85967707546495116780bf51f20bd79ca8bc6787b6fcb51

Contents?: true

Size: 683 Bytes

Versions: 11

Compression:

Stored size: 683 Bytes

Contents

# frozen_string_literal: true

module HermesMessengerOfTheGods
  if defined?(ActiveModel::ValidationError)
    class ValidationError < ActiveModel::ValidationError; end
  else
    class ValidationError < StandardError
      attr_reader :model

      def initialize(model)
        @model = model
        errors = @model.errors.full_messages.join(', ')
        super(errors)
      end
    end
  end

  class MessageDispatchFailed < StandardError
    attr_accessor :exceptions
  end
  class MessageDispatchTotalFailure < MessageDispatchFailed; end
  class MessageDispatchPartialFailure < MessageDispatchFailed; end

  module Endpoints
    class FatalError < RuntimeError; end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
hermes_messenger_of_the_gods-2.4.0.pre2 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.4.0.pre1 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.3.4 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.3.3 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.3.2 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.3.1 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.3.0 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.2.0 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.1.1 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.1.0 lib/hermes_messenger_of_the_gods/exceptions.rb
hermes_messenger_of_the_gods-2.0.0 lib/hermes_messenger_of_the_gods/exceptions.rb