Bugzilla – Attachment 39297 Details for
Bug 14200
GetNormalizedISBN failing to normalize valid ISBNs in some cases
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14200 - GetNormalizedISBN failing to normalize valid ISBNs in some cases
Bug-14200---GetNormalizedISBN-failing-to-normalize.patch (text/plain), 1.36 KB, created by
Marcel de Rooy
on 2015-05-19 12:41:49 UTC
(
hide
)
Description:
Bug 14200 - GetNormalizedISBN failing to normalize valid ISBNs in some cases
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2015-05-19 12:41:49 UTC
Size:
1.36 KB
patch
obsolete
>From 1cd9795b4441a52ffd180a902d3b0a3daf8eb96c Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Thu, 14 May 2015 06:20:00 -0400 >Subject: [PATCH] Bug 14200 - GetNormalizedISBN failing to normalize valid > ISBNs in some cases >Content-Type: text/plain; charset=utf-8 > >For some reason the regular expression used to split the multiple ISBN >fields can fail which keeps Business::ISBN from being able to parse out >and return a valid isbn. Using split() instead of the regex fixes the >issue. > >Test Plan: >1) Apply the unit test patch first >2) prove t/Koha.t >3) Note the failures >4) Apply the second patch >5) prove t/Koha.t >6) Note all tests pass > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >Signed-off-by: Karen Bryant <kbryant@ccpl-fl.net> >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > C4/Koha.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/C4/Koha.pm b/C4/Koha.pm >index cb0ed5a..4f54a3b 100644 >--- a/C4/Koha.pm >+++ b/C4/Koha.pm >@@ -1487,7 +1487,7 @@ sub GetNormalizedISBN { > if ($isbn) { > # Koha attempts to store multiple ISBNs in biblioitems.isbn, separated by " | " > # anything after " | " should be removed, along with the delimiter >- $isbn =~ s/(.*)( \| )(.*)/$1/; >+ ($isbn) = split(/\|/, $isbn ); > return _isbn_cleanup($isbn); > } > return unless $record; >-- >1.7.10.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 14200
:
39178
|
39179
|
39197
|
39198
|
39296
| 39297