Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Small fix to prevent people going to /constituency without giving a n…

…ame.
  • Loading branch information...
commit 0bb9fcbe0631ecba3800d24e56aa256e9517cc44 1 parent d7b6999
Dave Cross authored
Showing with 4 additions and 0 deletions.
  1. +4 −0 PoliticalWeb/lib/PoliticalWeb.pm
4 PoliticalWeb/lib/PoliticalWeb.pm
View
@@ -35,6 +35,10 @@ get '/about/' => sub {
return $page;
};
+get '/constituency/?' => sub {
+ template 'index', { error => 'That constituency' };
+};
+
get '/constituency/:constname' => sub {
my $constit = get_const(params->{constname});
my $mp = get_mp($constit) if $constit;
Please sign in to comment.
Something went wrong with that request. Please try again.