[Rt-commit] [svn] r1286 - rt/branches/3.2-RELEASE/lib/RT
robert at pallas.eruditorum.org
robert at pallas.eruditorum.org
Mon Jul 26 15:15:12 EDT 2004
Author: robert
Date: Mon Jul 26 15:15:12 2004
New Revision: 1286
Modified:
/ (props changed)
rt/branches/3.2-RELEASE/lib/RT/Tickets_Overlay.pm
Log:
----------------------------------------------------------------------
r1291 at dog: rspier | 2004-07-26T19:14:41.133769Z
Revert the last microoptimization. It smells funny and will create problems with merging to 3.3
----------------------------------------------------------------------
Modified: rt/branches/3.2-RELEASE/lib/RT/Tickets_Overlay.pm
==============================================================================
--- rt/branches/3.2-RELEASE/lib/RT/Tickets_Overlay.pm (original)
+++ rt/branches/3.2-RELEASE/lib/RT/Tickets_Overlay.pm Mon Jul 26 15:15:12 2004
@@ -768,6 +768,10 @@
die "No custom field named $field found\n" unless $cfid;
+
+
+ my $null_columns_ok;
+
my $TicketCFs;
# Perform one Join per CustomField
if ($self->{_sql_keywordalias}{$cfid}) {
@@ -794,9 +798,12 @@
# If we're trying to find custom fields that don't match something, we want tickets
# where the custom field has no value at all
- if ( (uc $op eq "IS NOT" && uc $value ne "NULL")
- || uc $op eq "NOT LIKE"
- || $op eq '!=' ) {
+ if ( ($op =~ /^IS$/i) || ($op =~ /^NOT LIKE$/i) || ( $op eq '!=' ) ) {
+ $null_columns_ok = 1;
+ }
+
+
+ if ( $null_columns_ok && $op !~ /IS/i && uc $value ne "NULL") {
$self->_SQLLimit( ALIAS => $TicketCFs,
FIELD => 'Content',
OPERATOR => 'IS',
More information about the Rt-commit
mailing list