From 67fe5faa9f00747e83832fdf9803ccd0e3dfbc8e Mon Sep 17 00:00:00 2001 From: Dan Scott Date: Sun, 29 May 2011 23:36:44 -0400 Subject: [PATCH] Treat a Polish l as an ASCII l in full-text search Is this code path even hit these days? Would have expected naco_normalize to be poking around here if that was the case... Signed-off-by: Dan Scott --- Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/fts.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/fts.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/fts.pm index 2857e2aecc..a07196b42e 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/fts.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/fts.pm @@ -24,6 +24,9 @@ $term =~ s/(\pM+)//gos; $term =~ s/(\b\.\b)//gos; + $term =~ s/\x{142}/l/sgo; # Convert Polish l (lowercase) + $term =~ s/\x{141}/l/sgo; # Convert Polish l (uppercase) + # hack to normalize ratio-like strings while ($term =~ /\b\d{1}:[, ]?\d+(?:[ ,]\d+[^:])+/o) { $term = $` . join ('', split(/[, ]/, $&)) . $'; -- 2.11.0