Exception: BabySqueel::PolymorphicSpecificationError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/baby_squeel/errors.rb

Overview

:nodoc:

Constant Summary collapse

MESSAGE =
"'%{association}' is not a polymorphic association, therefore " \
"the following expression is invalid:" \
"\n\n  %{association}.of(%{klass})\n\n"

Instance Method Summary collapse

Constructor Details

#initialize(association, klass) ⇒ PolymorphicSpecificationError

Returns a new instance of PolymorphicSpecificationError.



44
45
46
# File 'lib/baby_squeel/errors.rb', line 44

def initialize(association, klass)
  super format(MESSAGE, association: association, klass: klass)
end