method

write_attribute

Importance_0
Ruby on Rails latest stable (v7.1.3.2) - 0 notes - Class: HasReadonlyAttributes
write_attribute(attr_name, value) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/readonly_attributes.rb, line 49
      def write_attribute(attr_name, value)
        if !new_record? && self.class.readonly_attribute?(attr_name.to_s)
          raise ReadonlyAttributeError.new(attr_name)
        end

        super
      end
Register or log in to add new notes.