[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
Sat Feb 1 21:23:22 CET 2020


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

David Nind <david at davidnind.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #98225|0                           |1
        is obsolete|                            |

--- Comment #2 from David Nind <david at davidnind.com> ---
Created attachment 98266
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=98266&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>

Signed-off-by: David Nind <david at davidnind.com>

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


More information about the Koha-bugs mailing list