Exception: Hooksmith::NoProcessorError

Inherits:
Error
  • Object
show all
Defined in:
lib/hooksmith/errors.rb

Overview

Raised when no processor is registered for an event.

This error can be raised when strict mode is enabled and no processor is found for a given provider/event combination.

Examples:

raise Hooksmith::NoProcessorError.new('stripe', 'unknown_event')

Instance Attribute Summary

Attributes inherited from Error

#event, #provider

Instance Method Summary collapse

Constructor Details

#initialize(provider, event) ⇒ NoProcessorError

Initializes a new NoProcessorError.

Parameters:

  • provider (String, Symbol)

    the provider name

  • event (String, Symbol)

    the event name



74
75
76
77
78
79
80
# File 'lib/hooksmith/errors.rb', line 74

def initialize(provider, event)
  super(
    "No processor registered for #{provider} event #{event}",
    provider:,
    event:
  )
end