Top Level Namespace
Defined Under Namespace
Modules: ActiveRecord, Arel, VirtualAttributes
Instance Method Summary collapse
Instance Method Details
#assert_klass_has_instance_method(klass, instance_method) ⇒ Object
120 121 122 123 124 125 |
# File 'lib/active_record/virtual_attributes/virtual_fields.rb', line 120 def assert_klass_has_instance_method(klass, instance_method) klass.instance_method(instance_method) rescue NameError => err msg = "#{klass} is missing the method our prepended code is expecting to patch. Was the undefined method removed or renamed upstream?\nSee: #{__FILE__}.\nThe NameError was: #{err}. " raise NameError, msg end |