Bug 22144: (QA follow-up) Prepare the ground for other formats
This patch refactors the original implementation so it is ready for
supporting other formats. It also adds some error handling.
To test:
- Apply this patch
- Run:
$ kshell
k$ prove t/db_dependent/Koha/Biblio/Metadata.t
=> SUCCESS: Tests pass!
- Sign off :-D
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>