]> git.evergreen-ils.org Git - Evergreen.git/commit
TPAC: Protect against missing 901c in legacy MARCXML
authorDan Scott <dscott@laurentian.ca>
Fri, 25 Nov 2011 17:30:24 +0000 (12:30 -0500)
committerBill Erickson <berick@esilibrary.com>
Tue, 6 Dec 2011 14:21:56 +0000 (09:21 -0500)
commitd71b923ea0f7d16b19bb7e98176609726867b98a
tree35c28939c5a82dafc164886924b5319b0d3cb1ef
parentc4e56c4c40c6a69887834a2fd5d7d099c9987097
TPAC: Protect against missing 901c in legacy MARCXML

Bad MARCXML to which Evergreen has been unable to add a 901c happens -
particularly with legacy MARCXML. Currently, TPAC crashes hard with an
ugly error if a 901c is not found when attempting to display the record
in search results. In comparison, the JSPAC displays the record without
a problem.

This commit logs a warning and enables the TPAC to continue somewhat
gracefully (the problem record is simply skipped in the search results).
A more robust solution may be to teach unapi.bre to add the record ID to
the results and to have the TPAC pull from that, rather than relying on
the MARCXML itself to contain the record ID.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Util.pm