aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2018-04-05 11:48:29 +0100
committerStruan Donald <struan@exo.org.uk>2018-04-25 10:41:07 +0100
commitb2da3f912d63c888791973099c506154c34839e8 (patch)
tree09467cfd43f4c4201becb97243dd630fa27bcf7f
parent6ce3a56583f5057bc40fd48ab0160d2b7e4a6a0a (diff)
better diagnostics for rejected Open311 problems
Add a more helpful error message when a problem fetched over Open311 is rejected for problems with the date.
-rw-r--r--perllib/Open311/GetServiceRequests.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/perllib/Open311/GetServiceRequests.pm b/perllib/Open311/GetServiceRequests.pm
index 48e35acab..2d15347fd 100644
--- a/perllib/Open311/GetServiceRequests.pm
+++ b/perllib/Open311/GetServiceRequests.pm
@@ -127,7 +127,8 @@ sub create_problems {
$updated_time->clone->set_time_zone('UTC')
);
if ($args->{start_date} && $args->{end_date} && ($updated lt $args->{start_date} || $updated gt $args->{end_date}) ) {
- warn "Problem id $request_id for @{[$body->name]} has an invalid time, not creating"
+ warn "Problem id $request_id for @{[$body->name]} has an invalid time, not creating: "
+ . "$updated either less than $args->{start_date} or greater than $args->{end_date}"
if $self->verbose;
next;
}