[Bps-public-commit] SD branch, master, updated. 0.73-20-g069619d

sunnavy at bestpractical.com sunnavy at bestpractical.com
Wed Oct 21 03:20:04 EDT 2009


The branch, master has been updated
       via  069619d34ffce7500e6679ba8a85a7175f3a6198 (commit)
      from  2747ad9f6e2a1464e4f9c0e829d93ffcdd847f38 (commit)

Summary of changes:
 lib/App/SD/Replica/gcode/PullEncoder.pm |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

- Log -----------------------------------------------------------------
commit 069619d34ffce7500e6679ba8a85a7175f3a6198
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Wed Oct 21 12:53:00 2009 +0800

    as long as there is no query stuff, we can try the ->updated_after method first

diff --git a/lib/App/SD/Replica/gcode/PullEncoder.pm b/lib/App/SD/Replica/gcode/PullEncoder.pm
index 06ad8ce..61785fe 100644
--- a/lib/App/SD/Replica/gcode/PullEncoder.pm
+++ b/lib/App/SD/Replica/gcode/PullEncoder.pm
@@ -108,15 +108,18 @@ sub find_matching_tickets {
               grep { $self->sync_source->gcode->$_ }
               qw/project email password/ );
 
-        if ( $last_changeset_seen_dt->epoch == 0 && keys %query == 0 ) {
+        if ( keys %query == 0 ) {
 
-            # so it's clone, we can use old updated_after method here
-            # load issue with the scrapping way, which is more effective
+            # we can use old updated_after method here if no query strings
+            # loading issue by checking feeds update is more effective, if
+            # possible
             local $Net::Google::Code::Issue::USE_HYBRID = 0;
             require Net::Google::Code::Issue::Search;
             my $search =
               Net::Google::Code::Issue::Search->new(
                 project => $self->sync_source->project, );
+
+            # 0 here is to not fallback to ->search method
             if ( $search->updated_after( $last_changeset_seen_dt, 0 ) ) {
                 return $search->results;
             }

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



More information about the Bps-public-commit mailing list