aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormatthew <matthew>2009-12-04 11:53:44 +0000
committermatthew <matthew>2009-12-04 11:53:44 +0000
commit96f33fba402e4c1d4918038efba0454c06f2f679 (patch)
treede03c85c9145cbed0050f52b6b9ed62ffaeaf5b6
parentdd721faeffdcf088d3d719bbb5a89b6beb2fa416 (diff)
Another tweak, don't show postcode twice.
-rw-r--r--perllib/Page.pm6
1 files changed, 2 insertions, 4 deletions
diff --git a/perllib/Page.pm b/perllib/Page.pm
index 70b77a88c..beecbd68b 100644
--- a/perllib/Page.pm
+++ b/perllib/Page.pm
@@ -6,7 +6,7 @@
# Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org; WWW: http://www.mysociety.org/
#
-# $Id: Page.pm,v 1.217 2009-12-04 11:49:28 matthew Exp $
+# $Id: Page.pm,v 1.218 2009-12-04 11:53:44 matthew Exp $
#
package Page;
@@ -956,10 +956,8 @@ sub geocode_string {
} elsif ($js =~ /}, *{/) { # Multiple
my @js = split /}, *{/, $js;
foreach (@js) {
- next unless /"address" *: *"(.*?)",\s*"AddressDetails" *:.*?"PostalCodeNumber" *: *"(.*?)"/gs;
+ next unless /"address" *: *"(.*?)"/s;
my $address = $1;
- my $pc = $2;
- $address =~ s/UK/$pc, UK/;
push (@$error, $address) unless $address =~ /BT\d/;
}
$error = _('Sorry, we could not find that location.') unless $error;