aboutsummaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authormatthew <matthew>2006-10-07 21:06:31 +0000
committermatthew <matthew>2006-10-07 21:06:31 +0000
commit03d55b3dca58bcb76673a9c3cd6ca18c17a4610a (patch)
treec1b07f628dd55c4a9a0d392f260cbb743cff12cd /bin
parentc3d00850232f9ee73c73e34e9ea671deaeba1b9e (diff)
Let's not perform a needless nested loop on every mousemove shall we?
Dragging should be much quicker now.
Diffstat (limited to 'bin')
-rwxr-xr-xbin/councils-no-contact12
1 files changed, 6 insertions, 6 deletions
diff --git a/bin/councils-no-contact b/bin/councils-no-contact
index 22b2f53e1..22855aaf0 100755
--- a/bin/councils-no-contact
+++ b/bin/councils-no-contact
@@ -6,7 +6,7 @@
# Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org. WWW: http://www.mysociety.org
#
-# $Id: councils-no-contact,v 1.1 2006-09-27 13:51:22 matthew Exp $
+# $Id: councils-no-contact,v 1.2 2006-10-07 21:06:31 matthew Exp $
use strict;
require 5.8.0;
@@ -93,12 +93,12 @@ foreach my $type (@$types) {
my $areas_info = mySociety::MaPit::get_voting_areas_info($areas);
foreach my $id (keys %$areas_info) {
my $area_info = $areas_info->{$id};
- my $name = $area_info->{name};
- foreach my $council (@councils_no_email) {
- if ($name =~ /^$council( ((Borough|City|District|County) )*Council)?$/) {
+ my $name = $area_info->{name};
+ foreach my $council (@councils_no_email) {
+ if ($name =~ /^$council( ((Borough|City|District|County) )*Council)?$/) {
push(@out, $id);
- }
- }
+ }
+ }
}
}