aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App/Controller
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2019-06-10 11:50:43 +0100
committerMatthew Somerville <matthew@mysociety.org>2019-06-10 11:50:43 +0100
commit9af4e168bdd09e6e818794f448443284681cc7fd (patch)
tree093ebd62ec8a06bcae5fa1bfa9936b6d87035407 /perllib/FixMyStreet/App/Controller
parent9f82fbb4088e32a3ca636a5ccc1e7495e34e73e5 (diff)
[Hounslow] Couple more council references (RSS related).
Diffstat (limited to 'perllib/FixMyStreet/App/Controller')
-rw-r--r--perllib/FixMyStreet/App/Controller/Report/New.pm4
-rw-r--r--perllib/FixMyStreet/App/Controller/Reports.pm4
2 files changed, 3 insertions, 5 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Report/New.pm b/perllib/FixMyStreet/App/Controller/Report/New.pm
index 156c81065..6a6040865 100644
--- a/perllib/FixMyStreet/App/Controller/Report/New.pm
+++ b/perllib/FixMyStreet/App/Controller/Report/New.pm
@@ -202,9 +202,7 @@ sub report_form_ajax : Path('ajax') : Args(0) {
my @list_of_names = map { $_->name } values %{$c->stash->{bodies}};
my %display_names = map {
- my $name = $_->get_cobrand_handler && $_->get_cobrand_handler->can('council_name')
- ? $_->get_cobrand_handler->council_name
- : $_->name;
+ my $name = $_->cobrand_name;
( $_->name ne $name ) ? ( $_->name => $name ) : ();
} values %{$c->stash->{bodies}};
my $contribute_as = {};
diff --git a/perllib/FixMyStreet/App/Controller/Reports.pm b/perllib/FixMyStreet/App/Controller/Reports.pm
index fc5176a07..9b33b42b4 100644
--- a/perllib/FixMyStreet/App/Controller/Reports.pm
+++ b/perllib/FixMyStreet/App/Controller/Reports.pm
@@ -287,12 +287,12 @@ sub rss_ward : Path('/rss/reports') : Args(2) {
if ($c->stash->{ward}) {
# Problems sent to a council, restricted to a ward
$c->stash->{type} = 'ward_problems';
- $c->stash->{title_params} = { COUNCIL => $c->stash->{body}->name, WARD => $c->stash->{ward}{name} };
+ $c->stash->{title_params} = { COUNCIL => $c->stash->{body}->cobrand_name, WARD => $c->stash->{ward}{name} };
$c->stash->{db_params} = [ $c->stash->{body}->id, $c->stash->{ward}->{id} ];
} else {
# Problems sent to a council
$c->stash->{type} = 'council_problems';
- $c->stash->{title_params} = { COUNCIL => $c->stash->{body}->name };
+ $c->stash->{title_params} = { COUNCIL => $c->stash->{body}->cobrand_name };
$c->stash->{db_params} = [ $c->stash->{body}->id ];
}