diff options
author | Matthew Somerville <matthew-github@dracos.co.uk> | 2017-10-04 18:17:13 +0100 |
---|---|---|
committer | Matthew Somerville <matthew-github@dracos.co.uk> | 2017-10-10 23:16:14 +0100 |
commit | 5934b383754a2d298100a674a1ccefc2cb9e50af (patch) | |
tree | 81f0e217836eddea478bea268371ec02b5887942 /perllib/FixMyStreet/App/Controller/Around.pm | |
parent | 6f0ee01f37029c0fdabd161646b8dbbdec676165 (diff) |
Simplify geocode cache read/writing.
Don't think the return data ever needs decoding.
Diffstat (limited to 'perllib/FixMyStreet/App/Controller/Around.pm')
-rw-r--r-- | perllib/FixMyStreet/App/Controller/Around.pm | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Around.pm b/perllib/FixMyStreet/App/Controller/Around.pm index b872084ff..44ccb5259 100644 --- a/perllib/FixMyStreet/App/Controller/Around.pm +++ b/perllib/FixMyStreet/App/Controller/Around.pm @@ -338,10 +338,8 @@ sub _geocode : Private { } else { if ( ref($suggestions) eq 'ARRAY' ) { foreach (@$suggestions) { - my $address = $_->{address}; - $address = decode_utf8($address) if !utf8::is_utf8($address); - push @addresses, $address; - push @locations, { address => $address, lat => $_->{latitude}, long => $_->{longitude} }; + push @addresses, $_->{address}; + push @locations, { address => $_->{address}, lat => $_->{latitude}, long => $_->{longitude} }; } $response = { suggestions => \@addresses, locations => \@locations }; } else { |