Exception: Endpoints::Uuids::Search::CriteriaInvalid

Inherits:
Core::Service::Error show all
Defined in:
app/api/endpoints/uuids.rb

Overview

rubocop:todo Style/Documentation

Instance Method Summary collapse

Methods included from Core::Service::Error::Behaviour

included

Constructor Details

#initialize(*args) ⇒ CriteriaInvalid

Returns a new instance of CriteriaInvalid.


30
31
32
33
# File 'app/api/endpoints/uuids.rb', line 30

def initialize(*args)
  super
  @errors = { lookup: [message] }
end

Instance Method Details

#api_error(response) ⇒ Object


35
36
37
# File 'app/api/endpoints/uuids.rb', line 35

def api_error(response)
  response.content_error(422, @errors)
end