From 9a53e9810be94f44b1dd1f48d536442d0020ae26 Mon Sep 17 00:00:00 2001 From: Matthew Somerville Date: Tue, 17 Oct 2023 10:51:49 +0100 Subject: [PATCH] [TfL] Add config for including extra bodies on the site. --- perllib/FixMyStreet/Cobrand/TfL.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/perllib/FixMyStreet/Cobrand/TfL.pm b/perllib/FixMyStreet/Cobrand/TfL.pm index f6889480ec2..ae995a235a7 100644 --- a/perllib/FixMyStreet/Cobrand/TfL.pm +++ b/perllib/FixMyStreet/Cobrand/TfL.pm @@ -96,7 +96,8 @@ sub base_url_for_report { sub categories_restriction { my ($self, $rs) = @_; - $rs = $rs->search( { 'body.name' => [ 'TfL', 'National Highways' ] } ); + my $bodies = $self->feature('categories_restriction_bodies') || [ 'TfL', 'National Highways' ]; + $rs = $rs->search( { 'body.name' => $bodies } ); return $rs unless $self->{c}->stash->{categories_for_point}; # Admin page return $rs->search( { category => { -not_in => $self->_tfl_no_resend_categories } } ); }