diff options
-rw-r--r-- | perllib/FixMyStreet/App/Controller/Admin.pm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Admin.pm b/perllib/FixMyStreet/App/Controller/Admin.pm index 141aa516d..405ee37ec 100644 --- a/perllib/FixMyStreet/App/Controller/Admin.pm +++ b/perllib/FixMyStreet/App/Controller/Admin.pm @@ -796,11 +796,13 @@ sub stats : Path('stats') : Args(0) { $field = 'created' if $c->req->param('unconfirmed'); + my $one_day = DateTime::Duration->new( days => 1 ); + my $p = $c->model('DB::Problem')->search( { -AND => [ - $field => { '>=', $start_date->ymd }, - $field => { '<=', $end_date->ymd }, + $field => { '>=', $start_date}, + $field => { '<=', $end_date + $one_day }, ], }, { |