Exception: OpenReceive::Server::ValidationError
- Inherits:
-
StandardError
- Object
- StandardError
- OpenReceive::Server::ValidationError
- Defined in:
- lib/openreceive/server/errors.rb
Overview
400 — the request body/params were malformed or violated a contract rule.
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(message = "Invalid request.") ⇒ ValidationError
constructor
A new instance of ValidationError.
Constructor Details
#initialize(message = "Invalid request.") ⇒ ValidationError
Returns a new instance of ValidationError.
28 29 30 31 32 |
# File 'lib/openreceive/server/errors.rb', line 28 def initialize( = "Invalid request.") super() @status = 400 @code = "INVALID_REQUEST" end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
26 27 28 |
# File 'lib/openreceive/server/errors.rb', line 26 def code @code end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
26 27 28 |
# File 'lib/openreceive/server/errors.rb', line 26 def status @status end |