[Koha-bugs] [Bug 25913] New: Internal server error when calling get_coins on record with no title (245) but with 880 linked to 245
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Thu Jul 2 14:01:15 CEST 2020
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25913
Bug ID: 25913
Summary: Internal server error when calling get_coins on record
with no title (245) but with 880 linked to 245
Change sponsored?: ---
Product: Koha
Version: master
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P5 - low
Component: Lists
Assignee: koha-bugs at lists.koha-community.org
Reporter: nick at bywatersolutions.com
QA Contact: testopia at bugs.koha-community.org
CC: m.de.rooy at rijksmuseum.nl
In opac search results we call get_coins in an eval so it can load, on other
scripts we don't
The get_coins routine calls:
$title = $record->field('245')->as_string('ab');
With no check that the 245 exists.
Simple fix would be to call get_coins in an eval everywhere
More comprehensive would be to fall back to 880 field linked ot 245, and then
fallback to blank
This only affects MARC21 I believe as the UNIMARC implementation gets the field
directly without as_string
To recreate:
1 - Load attached record or create a record with 880 and no 245
2 - Enable COinSinOpac
3 - Search for record in staff or opac, it loads in results
4 - Add item to a public list, cannot view in opac
5 - Try to view ISBD or MARC tab on staff client, it fails
When indexing in ES we convert an 880 to its linked field so the record is
searchable, so we could make that a sbroutine
--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
More information about the Koha-bugs
mailing list