[Rt-commit] r4043 - in Jifty-DBI/trunk: . lib/Jifty/DBI

jesse at bestpractical.com jesse at bestpractical.com
Sun Nov 6 19:13:52 EST 2005


Author: jesse
Date: Sun Nov  6 19:13:52 2005
New Revision: 4043

Modified:
   Jifty-DBI/trunk/   (props changed)
   Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm
Log:
 r18426 at truegrounds:  jesse | 2005-11-06 19:12:18 -0500
 minor cleanups to build_select_count_query


Modified: Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm
==============================================================================
--- Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm	(original)
+++ Jifty-DBI/trunk/lib/Jifty/DBI/Collection.pm	Sun Nov  6 19:13:52 2005
@@ -386,12 +386,11 @@
 sub build_select_count_query {
     my $self = shift;
 
-    # TODO: refactor DoSearch and do_count such that we only have one
-    # place where we build most of the querystring
     my $QueryString = $self->_build_joins . " ";
 
-    $QueryString .= $self->_where_clause . " "
-        if ( $self->_is_limited > 0 );
+    if ( $self->_is_limited ) {
+        $QueryString .= $self->_where_clause . " "
+    }
 
     # DISTINCT query only required for multi-table selects
     if ( $self->_is_joined ) {


More information about the Rt-commit mailing list