From 1a1bfff12415a7793fee22bcd4e5e39e10dbd4d3 Mon Sep 17 00:00:00 2001 From: Matthew Somerville Date: Fri, 22 Apr 2016 16:48:57 +0100 Subject: Fallback if request to Gaze fails. Fixes #1286. --- perllib/FixMyStreet/Map/Google.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'perllib/FixMyStreet/Map/Google.pm') diff --git a/perllib/FixMyStreet/Map/Google.pm b/perllib/FixMyStreet/Map/Google.pm index 46823f358..8ddf4f4e9 100644 --- a/perllib/FixMyStreet/Map/Google.pm +++ b/perllib/FixMyStreet/Map/Google.pm @@ -7,7 +7,7 @@ package FixMyStreet::Map::Google; use strict; -use mySociety::Gaze; +use FixMyStreet::Gaze; use Utils; use constant ZOOM_LEVELS => 6; @@ -30,7 +30,7 @@ sub display_map { # Adjust zoom level dependent upon population density my $dist = $c->stash->{distance} - || mySociety::Gaze::get_radius_containing_population( $params{latitude}, $params{longitude}, 200_000 ); + || FixMyStreet::Gaze::get_radius_containing_population( $params{latitude}, $params{longitude} ); my $default_zoom = $c->cobrand->default_map_zoom() ? $c->cobrand->default_map_zoom() : $numZoomLevels - 4; $default_zoom = $numZoomLevels - 3 if $dist < 10; -- cgit v1.2.3