[Bps-public-commit] SD branch, master, updated. 5895e512b1e94cbb5b5060e77e4f68cc0780f80f
sunnavy at bestpractical.com
sunnavy at bestpractical.com
Thu Jun 4 02:10:24 EDT 2009
The branch, master has been updated
via 5895e512b1e94cbb5b5060e77e4f68cc0780f80f (commit)
from 1b56582776038fd784f2570e739409cfd002259b (commit)
Summary of changes:
lib/App/SD/Replica/gcode/PullEncoder.pm | 21 +++++----------------
1 files changed, 5 insertions(+), 16 deletions(-)
- Log -----------------------------------------------------------------
commit 5895e512b1e94cbb5b5060e77e4f68cc0780f80f
Author: sunnavy <sunnavy at gmail.com>
Date: Thu Jun 4 14:10:13 2009 +0800
use gcode's updated_after api to find ticiets
diff --git a/lib/App/SD/Replica/gcode/PullEncoder.pm b/lib/App/SD/Replica/gcode/PullEncoder.pm
index 41c11f5..bb19cce 100644
--- a/lib/App/SD/Replica/gcode/PullEncoder.pm
+++ b/lib/App/SD/Replica/gcode/PullEncoder.pm
@@ -76,23 +76,12 @@ sub find_matching_tickets {
project => $self->sync_source->project,
);
- $search->search(
- can => 'all',
- q => $query{query},
- limit => '99999',
- );
-
- my @base_results = @{ $search->results };
- my @results;
-
- foreach my $item (@base_results) {
- if ( !$last_changeset_seen_dt
- || ( $item->updated >= $last_changeset_seen_dt ) )
- {
- push @results, $item;
- }
+ if ( $search->updated_after($last_changeset_seen_dt) ) {
+ return $search->results;
+ }
+ else {
+ return [];
}
- return \@results;
}
sub translate_ticket_state {
-----------------------------------------------------------------------
More information about the Bps-public-commit
mailing list