Exception: Mongoid::Errors::ReadonlyAttribute
- Inherits:
-
MongoidError
- Object
- StandardError
- MongoidError
- Mongoid::Errors::ReadonlyAttribute
- Defined in:
- lib/mongoid/errors/readonly_attribute.rb
Overview
This error is raised when attempting the change the value of a readonly attribute after the document has been persisted.
Constant Summary
Constants inherited from MongoidError
Instance Method Summary collapse
-
#initialize(name, value) ⇒ ReadonlyAttribute
constructor
Create the new error.
Methods inherited from MongoidError
Constructor Details
#initialize(name, value) ⇒ ReadonlyAttribute
Create the new error.
18 19 20 21 22 |
# File 'lib/mongoid/errors/readonly_attribute.rb', line 18 def initialize(name, value) super( ("readonly_attribute", { name: name, value: value }) ) end |