aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/SendReport/Email.pm
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2012-12-14 19:07:08 +0000
committerMatthew Somerville <matthew@mysociety.org>2012-12-19 14:43:26 +0000
commitddf9dbdbf6486c781ca4a5822614b0b7cee2c062 (patch)
tree09c12affc3390138b03292d3f90810287b4941d0 /perllib/FixMyStreet/SendReport/Email.pm
parentda29e8a75eaa92e98807ad89d29d3d1f3c01bc14 (diff)
Allow bodies to span multiple area IDs, and areas can be covered by more than one body.
Diffstat (limited to 'perllib/FixMyStreet/SendReport/Email.pm')
-rw-r--r--perllib/FixMyStreet/SendReport/Email.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perllib/FixMyStreet/SendReport/Email.pm b/perllib/FixMyStreet/SendReport/Email.pm
index 5277b639a..b7c15a643 100644
--- a/perllib/FixMyStreet/SendReport/Email.pm
+++ b/perllib/FixMyStreet/SendReport/Email.pm
@@ -21,8 +21,8 @@ sub build_recipient_list {
my ($body_email, $confirmed, $note) = ( $contact->email, $contact->confirmed, $contact->note );
- $body_email = essex_contact($row->latitude, $row->longitude) if $body->area_id == 2225;
- $body_email = oxfordshire_contact($row->latitude, $row->longitude) if $body->area_id == 2237 && $body_email eq 'SPECIAL';
+ $body_email = essex_contact($row->latitude, $row->longitude) if $body->areas->{2225};
+ $body_email = oxfordshire_contact($row->latitude, $row->longitude) if $body->areas->{2237} && $body_email eq 'SPECIAL';
unless ($confirmed) {
$all_confirmed = 0;