[Rt-commit] rt branch, 4.2/less-sensitive-case-sensitive-check, created. rt-4.1.8-592-g4837030

Thomas Sibley trs at bestpractical.com
Thu Jun 13 20:02:34 EDT 2013


The branch, 4.2/less-sensitive-case-sensitive-check has been created
        at  4837030b0485a7d9f362f2239aa336612a0e4b04 (commit)

- Log -----------------------------------------------------------------
commit f77d6a941dbb31f83cf7f9ab94fd0ee4e8cf4091
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Thu Jun 13 16:44:04 2013 -0700

    Tidy up a small bit of POD
    
    Fix two typos and link the DatabaseType option.

diff --git a/lib/RT/Handle.pm b/lib/RT/Handle.pm
index 9cceb0a..46df34c 100644
--- a/lib/RT/Handle.pm
+++ b/lib/RT/Handle.pm
@@ -60,9 +60,9 @@ RT::Handle - RT's database handle
 
 C<RT::Handle> is RT specific wrapper over one of L<DBIx::SearchBuilder::Handle>
 classes. As RT works with different types of DBs we subclass repsective handler
-from L<DBIx::SerachBuilder>. Type of the DB is defined by C<DatabasseType> RT's
-config option. You B<must> load this module only when the configs have been
-loaded.
+from L<DBIx::SearchBuilder>. Type of the DB is defined by L<RT's DatabaseType
+config option|RT_Config/DatabaseType>. You B<must> load this module only when
+the configs have been loaded.
 
 =cut
 

commit 0ebb8b95a56df2de58d868cc4f701dbbe0ed486e
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Thu Jun 13 16:53:36 2013 -0700

    Don't check case sensitivity of Limit when the value isn't quoted
    
    An unquoted value means raw SQL which won't be made case-insensitive by
    DBIx::SearchBuilder anyway (refer to _GenericRestriction).
    
    This ensures that the 4.1.13 backcompat file doesn't erroneously produce
    case-sensitivity warnings.

diff --git a/lib/RT/SearchBuilder.pm b/lib/RT/SearchBuilder.pm
index 8773e69..3dd82b7 100644
--- a/lib/RT/SearchBuilder.pm
+++ b/lib/RT/SearchBuilder.pm
@@ -820,7 +820,7 @@ sub Limit {
         );
     }
 
-    unless ( exists $ARGS{CASESENSITIVE} ) {
+    unless ( exists $ARGS{CASESENSITIVE} or (exists $ARGS{QUOTEVALUE} and not $ARGS{QUOTEVALUE}) ) {
         if ( $ARGS{'OPERATOR'} !~ /IS/i
             && $table && $check_case_sensitivity{ lc $table }{ lc $ARGS{'FIELD'} }
         ) {

commit 4837030b0485a7d9f362f2239aa336612a0e4b04
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Thu Jun 13 16:58:19 2013 -0700

    Define a filename and line number when eval-ing backcompat files
    
    This greatly improves the ability to debug backcompat files given a
    stacktrace.  It turns "at eval (42) line 5" into a real filename and
    correct line number.

diff --git a/sbin/rt-setup-database.in b/sbin/rt-setup-database.in
index 585a88f..4ef5b82 100644
--- a/sbin/rt-setup-database.in
+++ b/sbin/rt-setup-database.in
@@ -275,7 +275,7 @@ sub action_insert {
 
     for my $file (@{$args{backcompat} || []}) {
         my $lines = do {local $/; local @ARGV = ($file); <>};
-        my $sub = eval "sub {\n$lines\n}";
+        my $sub = eval "sub {\n# line 1 $file\n$lines\n}";
         unless ($sub) {
             warn "Failed to load backcompat $file: $@";
             next;

-----------------------------------------------------------------------


More information about the Rt-commit mailing list