aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2011-05-09 12:58:26 +0100
committerStruan Donald <struan@exo.org.uk>2011-05-09 12:58:26 +0100
commit717a87caaeab4d76f30359360be9c620edab0abb (patch)
tree6b527ea4b7fc91d2e465983222fde8df56378b9a /perllib/FixMyStreet/App
parentd01b9bc2e42e46d5415a5464eb2ee063f43a8464 (diff)
move remove redundant council code into cobrands
Diffstat (limited to 'perllib/FixMyStreet/App')
-rw-r--r--perllib/FixMyStreet/App/Controller/Council.pm31
1 files changed, 1 insertions, 30 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Council.pm b/perllib/FixMyStreet/App/Controller/Council.pm
index 843a25499..53f7e38d8 100644
--- a/perllib/FixMyStreet/App/Controller/Council.pm
+++ b/perllib/FixMyStreet/App/Controller/Council.pm
@@ -63,7 +63,7 @@ sub load_and_check_councils : Private {
}
# edit hash in-place
- _remove_redundant_councils($all_councils) if $c->stash->{remove_redundant_councils};
+ $c->cobrand->remove_redundant_councils($all_councils) if $c->stash->{remove_redundant_councils};
# If we don't have any councils we can't accept the report
if ( !scalar keys %$all_councils ) {
@@ -78,35 +78,6 @@ sub load_and_check_councils : Private {
return 1;
}
-# TODO - should not be here.
-# These are country specific tweaks that should be in the cobrands
-sub _remove_redundant_councils {
- my $all_councils = shift;
-
- # UK specific tweaks
- if ( FixMyStreet->config('COUNTRY') eq 'GB' ) {
-
- # Ipswich & St Edmundsbury are responsible for everything in their
- # areas, not Suffolk
- delete $all_councils->{2241}
- if $all_councils->{2446} #
- || $all_councils->{2443};
-
- # Norwich is responsible for everything in its areas, not Norfolk
- delete $all_councils->{2233} #
- if $all_councils->{2391};
- }
-
- # Norway specific tweaks
- if ( FixMyStreet->config('COUNTRY') eq 'NO' ) {
-
- # Oslo is both a kommune and a fylke, we only want to show it once
- delete $all_councils->{301} #
- if $all_councils->{3};
- }
-
-}
-
=head1 AUTHOR
Struan Donald