Exception: ConvenientService::Service::Plugins::HasJSendResult::Entities::Result::Plugins::RaisesOnNotCheckedResultStatus::Exceptions::StatusIsNotChecked

Inherits:
Exception
  • Object
show all
Defined in:
lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/raises_on_not_checked_result_status/exceptions.rb

Instance Method Summary collapse

Methods inherited from Exception

new

Instance Method Details

#initialize_with_kwargs(attribute:) ⇒ Object



13
14
15
16
17
18
19
20
21
# File 'lib/convenient_service/service/plugins/has_j_send_result/entities/result/plugins/raises_on_not_checked_result_status/exceptions.rb', line 13

def initialize_with_kwargs(attribute:)
  message = <<~TEXT
    Attribute `#{attribute}` is accessed before result status is checked.

    Did you forget to call `success?`, `failure?`, or `error?` on result?
  TEXT

  initialize(message)
end