aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perllib/FixMyStreet/App/Controller/Dashboard.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Dashboard.pm b/perllib/FixMyStreet/App/Controller/Dashboard.pm
index b5f65d8c8..25c6e1923 100644
--- a/perllib/FixMyStreet/App/Controller/Dashboard.pm
+++ b/perllib/FixMyStreet/App/Controller/Dashboard.pm
@@ -195,7 +195,7 @@ sub export_as_csv {
(defined $value and length $value) ? ($_, $value) : ()
} sort keys %where };
- my $csv = Text::CSV->new();
+ my $csv = Text::CSV->new({ binary => 1, eol => "\n" });
$csv->combine(
'Report ID',
'Title',
@@ -264,7 +264,7 @@ sub export_as_csv {
}
$c->res->content_type('text/csv; charset=utf-8');
$c->res->header('content-disposition' => "attachment; filename=${filename}.csv");
- $c->res->body( join "\n", @body );
+ $c->res->body( join "", @body );
}
sub updates_search : Private {