Exception: ActiveAttr::UnknownAttributeError

Inherits:
NoMethodError
  • Object
show all
Includes:
Error
Defined in:
lib/active_attr/unknown_attribute_error.rb

Overview

This exception is raised if attempting to assign unknown attributes when using Attributes

Examples:

Rescuing an UnknownAttributeError error

begin
  person.write_attribute(:middle_initial, "J")
rescue ActiveAttr::UnknownAttributeError
  logger.error "attempted to write an unknown attribute"
  raise
end

Since:

  • 0.3.0