Bug 33482: Propagate errors from EBSCO's ws to the UI
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 11 Apr 2023 11:46:51 +0000 (13:46 +0200)
committerTomas Cohen Arazi <tomascohen@theke.io>
Fri, 5 May 2023 12:13:18 +0000 (09:13 -0300)
commitaf34d97928215c10b97c7c86d72da2b9ebde085f
tree2930e8fc8eaacedf46be595af718bb837ab543eb
parent7ca83d4b8c5581646af50d8378003b4233ad5fa2
Bug 33482: Propagate errors from EBSCO's ws to the UI

When adding or removing eholdings from EBSCO, if an error happens it is
lost and not propagated to the UI.

We were missing a return in the logic, and always returning 200

Test plan:
Do not apply (or revert) bug 33481
Configure EBSCO for ERM and add a package to your holdings
With this patch applied you will get a 500 that is propagated to the UI
Without this patch nothing happens and the user is not aware that
something bad happened

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Koha/REST/V1/ERM/EHoldings/Packages/EBSCO.pm