diff options
author | Struan Donald <struan@exo.org.uk> | 2011-08-11 12:13:10 +0100 |
---|---|---|
committer | Struan Donald <struan@exo.org.uk> | 2011-08-11 12:13:10 +0100 |
commit | 9e08472ee0f61a9b64d51c8c0847e3e40d6df66a (patch) | |
tree | 7d6fa3471f0eae48838d2f1a3fb926cf60114289 /bin | |
parent | 417f83fc0319ab3957b7c48d508f4ae99f7c290e (diff) |
tweak to problem fetching query to correctly exclude problems with no external_id
Diffstat (limited to 'bin')
-rw-r--r-- | bin/open311-update-reports | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/bin/open311-update-reports b/bin/open311-update-reports index 292c0e937..81a0394b8 100644 --- a/bin/open311-update-reports +++ b/bin/open311-update-reports @@ -30,9 +30,11 @@ while ( my $council = $council_list->next ) { my $reports = FixMyStreet::App->model('DB::Problem')->search( { council => { like => "\%$area_id\%" }, - external_id => { '!=', undef }, - external_id => { '!=', '' }, - state => { 'IN', [qw/confirmed fixed/] } + state => { 'IN', [qw/confirmed fixed/] }, + -and => [ + external_id => { '!=', undef }, + external_id => { '!=', '' }, + ], } ); |