[open-ils-commits] r13487 - branches/rel_1_6_0/Open-ILS/src/perlmods/OpenILS/WWW (dbs)

svn at svn.open-ils.org svn at svn.open-ils.org
Mon Jun 29 22:59:59 EDT 2009


Author: dbs
Date: 2009-06-29 22:59:57 -0400 (Mon, 29 Jun 2009)
New Revision: 13487

Modified:
   branches/rel_1_6_0/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm
Log:
Treat SRU queries as UTF8 input.

Resolves a problem whereby any non-ASCII input in SRU queries resulted in searches for corrupted strings (and consequently 0 hits)


Modified: branches/rel_1_6_0/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm
===================================================================
--- branches/rel_1_6_0/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm	2009-06-30 02:56:54 UTC (rev 13486)
+++ branches/rel_1_6_0/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm	2009-06-30 02:59:57 UTC (rev 13487)
@@ -1608,8 +1608,8 @@
 	my ($shortname, $holdings) = $url =~ m#/?([^/]*)(/holdings)?#;
 
 	if ( $resp->type eq 'searchRetrieve' ) {
-		my $cql_query = $req->query;
-		my $search_string = $req->cql->toEvergreen;
+		my $cql_query = decode_utf8($req->query);
+		my $search_string = decode_utf8($req->cql->toEvergreen);
 
 		# Ensure the search string overrides the default site
 		if ($shortname and $search_string !~ m#site:#) {



More information about the open-ils-commits mailing list