Bug 14629 - [QA Followup] Pass invalid ISSN through GetVariationsOfISSN
authorNick Clemens <nick@bywatersolutions.com>
Thu, 31 Dec 2015 16:00:10 +0000 (16:00 +0000)
committerKyle M Hall <kyle@bywatersolutions.com>
Fri, 28 Oct 2016 11:58:14 +0000 (11:58 +0000)
commit0963dc4da6b77d02ba798a6605685531ddccfcf4
tree372bee4a93065c234ec6c2e32936f372204ed936
parent68ced964fd254e7cba67a9b1b867907c557888c4
Bug 14629 - [QA Followup] Pass invalid ISSN through GetVariationsOfISSN

This is an optional follow up depending on community opinion.

While copying over the code form the ISBN portion I noticed that with
aggressive matching enabled invalid ISBNs (and hence ISSNs) were being
stripped from the record.

I think in the case of a library exporting records, making changes, and
reimporting they would expect to get a match on ISSN or ISBN whether or
not the number is valid.

This patch changes the subroutine to return the original ISSN in the
case of it being invalid.

To test:
With first patch only export a record with an invalid ISSN and reimport
with AggressiveMatchOnISSN enabled and match on ISSN - you should not get a match
Apply this patch
reimport the file and you should find a match.

Signed-off-by: Chad Roseburg <croseburg@ncrl.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
C4/Koha.pm
t/Koha.t