[Koha-bugs] [Bug 24554] Only embed relations from Koha::Biblio in to_api

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jan 31 13:11:20 CET 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24554

--- Comment #1 from Tomás Cohen Arazi <tomascohen at gmail.com> ---
Created attachment 98225
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=98225&action=edit
Bug 24554: Only embed relations from Koha::Biblio in to_api

This patch simplifies the behaviour of Koha::Biblio->to_api. It was
designed with the idea of handling possible methods that would be added
to Koha::Biblioitem. But it had a weird fallback behaviour was
highlighted by using it with bug 24528.

On fixing it it become obvious that it was unnessessarily complex and
that it was not worth. That's the reason there wasn't any test for it,
as Koha::Biblioitem doesn't implement any extra methods.

To test:
1. Run:
   $ kshell
  k$ prove t/db_dependent/Koha/Biblio.t
=> SUCCESS: Tests pass
2. Apply this patch
3. Repeat (1)
=> SUCCESS: Tests pass!
4. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen at theke.io>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list