Exception: JSONAPI::Exceptions::RecordLocked
- Defined in:
- lib/jsonapi/exceptions.rb
Instance Attribute Summary collapse
-
#message ⇒ Object
Returns the value of attribute message.
Instance Method Summary collapse
- #errors ⇒ Object
-
#initialize(message) ⇒ RecordLocked
constructor
A new instance of RecordLocked.
Constructor Details
#initialize(message) ⇒ RecordLocked
Returns a new instance of RecordLocked.
364 365 366 |
# File 'lib/jsonapi/exceptions.rb', line 364 def initialize() = end |
Instance Attribute Details
#message ⇒ Object
Returns the value of attribute message.
363 364 365 |
# File 'lib/jsonapi/exceptions.rb', line 363 def end |
Instance Method Details
#errors ⇒ Object
368 369 370 371 372 373 374 |
# File 'lib/jsonapi/exceptions.rb', line 368 def errors [JSONAPI::Error.new(code: JSONAPI::LOCKED, status: :locked, title: I18n.translate('jsonapi-resources.exceptions.record_locked.title', default: 'Locked resource'), detail: "#{message}")] end |