diff options
author | Matthew Somerville <matthew@mysociety.org> | 2016-08-10 10:26:59 +0100 |
---|---|---|
committer | Matthew Somerville <matthew@mysociety.org> | 2016-08-10 10:27:01 +0100 |
commit | 1a290e7812432acab20e21a30f66a1b00e683bce (patch) | |
tree | 1c701ce38e005280033a478acfa9dabdfba7f82e /perllib/Open311 | |
parent | 92cb0c39c691416344c7c3b577508814efe61ee2 (diff) |
Skip incoming Open311 update if no ID or content.
Diffstat (limited to 'perllib/Open311')
-rw-r--r-- | perllib/Open311/GetServiceRequestUpdates.pm | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/perllib/Open311/GetServiceRequestUpdates.pm b/perllib/Open311/GetServiceRequestUpdates.pm index 921b2996d..0751092fb 100644 --- a/perllib/Open311/GetServiceRequestUpdates.pm +++ b/perllib/Open311/GetServiceRequestUpdates.pm @@ -103,6 +103,7 @@ sub update_comments { $problem = $self->schema->resultset('Problem')->to_body($body)->search( $criteria ); if (my $p = $problem->first) { + next unless defined $request->{update_id} && defined $request->{description}; my $c = $p->comments->search( { external_id => $request->{update_id} } ); if ( !$c->first ) { |