Kohabug 2500 Fiction Call Number Splitting Enhancement/Bugfix
authorChris Nighswonger <cnighswonger@foundations.edu>
Thu, 26 Feb 2009 20:43:35 +0000 (15:43 -0500)
committerHenri-Damien LAURENT <henridamien.laurent@biblibre.com>
Tue, 26 May 2009 19:14:58 +0000 (21:14 +0200)
The current regexp used to split fiction call numbers does not handle the '.' char well. This patch corrects the regexp so that it behaves as expected.

This patch should be ported to the 3.0.x branch.

[fbcbug 5]

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
Signed-off-by: Henri-Damien LAURENT <henridamien.laurent@biblibre.com>
C4/Labels.pm

index 65c62a7..3a21bbd 100644 (file)
@@ -994,7 +994,7 @@ sub split_fcn {
     # Split fiction call numbers based on spaces
     SPLIT_FCN:
     while ($fcn) {
-        if ($fcn =~ m/([A-Za-z0-9]+)(\W?).*?/x) {
+        if ($fcn =~ m/([A-Za-z0-9]+\.?[0-9]?)(\W?).*?/x) {
             push (@fcn_split, $1);
             $fcn = $';
         }