]> git.koha-community.org Git - koha.git/commit
Bug 29857: Provide a generic full_message method for our exceptions
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 12 Jan 2022 09:30:59 +0000 (10:30 +0100)
committerFridolin Somers <fridolin.somers@biblibre.com>
Wed, 2 Mar 2022 08:47:47 +0000 (22:47 -1000)
commit7429f28cfc7a47a486a8ffb54473db4ed6292500
tree6ab99c96e85050c4e71dd62a6eec658c4a495b3a
parent42096deea48a355e9b070613eb943ab75b481e86
Bug 29857: Provide a generic full_message method for our exceptions

We pass useful information when throwing exceptions, but we don't
display them! We must display all the details we need when the exception
is stringified.

Test plan:

Use the following snippet:
  use Koha::Exceptions::Elasticsearch;
  Koha::Exceptions::Elasticsearch::BadResponse->throw( type => "a good type", details => "and some details" );

Execute it without and with the patch.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Koha/Exceptions/Exception.pm