aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet
diff options
context:
space:
mode:
Diffstat (limited to 'perllib/FixMyStreet')
-rw-r--r--perllib/FixMyStreet/Cobrand.pm3
-rw-r--r--perllib/FixMyStreet/Cobrand/Base.pm3
2 files changed, 4 insertions, 2 deletions
diff --git a/perllib/FixMyStreet/Cobrand.pm b/perllib/FixMyStreet/Cobrand.pm
index 6fe2a2bc8..ad21820d7 100644
--- a/perllib/FixMyStreet/Cobrand.pm
+++ b/perllib/FixMyStreet/Cobrand.pm
@@ -84,6 +84,9 @@ sub get_class_for_moniker {
return $avail if $moniker eq $avail->moniker;
}
+ # Special case for old blank cobrand entries in fixmystreet.com.
+ return 'FixMyStreet::Cobrand::FixMyStreet' if $moniker eq '';
+
# if none match then use the default
return 'FixMyStreet::Cobrand::Default';
}
diff --git a/perllib/FixMyStreet/Cobrand/Base.pm b/perllib/FixMyStreet/Cobrand/Base.pm
index 00b47d7da..42a891cb4 100644
--- a/perllib/FixMyStreet/Cobrand/Base.pm
+++ b/perllib/FixMyStreet/Cobrand/Base.pm
@@ -35,7 +35,6 @@ sub moniker {
my $class = ref( $_[0] ) || $_[0]; # deal with object or class
my ($last_part) = $class =~ m{::(\w+)$};
$last_part = lc($last_part);
- return '' if $last_part eq 'default';
return $last_part;
}
@@ -49,7 +48,7 @@ Returns true if this is the default cobrand, false otherwise.
sub is_default {
my $self = shift;
- return $self->moniker eq '';
+ return $self->moniker eq 'default';
}
=head2 path_to_web_templates