[open-ils-commits] [GIT] Evergreen ILS branch origin/rel_2_1 created. f77d48777eda1895dd30077baee73481ebe07e56
Evergreen Git
git at git.evergreen-ils.org
Mon Jun 13 09:51:55 EDT 2011
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".
The branch, origin/rel_2_1 has been created
at f77d48777eda1895dd30077baee73481ebe07e56 (commit)
- Log -----------------------------------------------------------------
commit f77d48777eda1895dd30077baee73481ebe07e56
Author: Dan Scott <dan at coffeecode.net>
Date: Mon Jun 13 09:45:39 2011 -0400
Prevent uninit var warnings in QueryParser.pm
$suffix_op and $prefix_op would not be defined if $suffix or $prefix did
not evaluate to true, leading to warnings about undefined variables in
open-ils.storage_stderr.log.
Signed-off-by: Dan Scott <dscott at laurentian.ca>
diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm
index b858fd5..8cd490c 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm
@@ -834,8 +834,11 @@ sub buildSQL {
my $suffix = $self->suffix || '';
$prefix = "'$prefix' ||" if $prefix;
- my $suffix_op = ":$suffix" if $suffix;
- my $suffix_after = "|| '$suffix_op'" if $suffix;
+ my $suffix_op = '';
+ my $suffix_after = '';
+
+ $suffix_op = ":$suffix" if $suffix;
+ $suffix_after = "|| '$suffix_op'" if $suffix;
$sql = "to_tsquery('$classname', COALESCE(NULLIF($prefix '(' || btrim(regexp_replace($sql,E'(?:\\\\s+|:)','$suffix_op&','g'),'&|') $suffix_after || ')', '()'), ''))";
-----------------------------------------------------------------------
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list