Don't need validation unless it's a POST (probably should re-think this whole route)
This commit is contained in:
parent
c0070041b7
commit
bfb9102d51
|
@ -62,7 +62,7 @@ under sub ($c) {
|
|||
get '/' => sub ($c) { $c->redirect_to(page => {page => 'view'}) };
|
||||
|
||||
any [qw{GET POST}], '/sign' => sub ($c) {
|
||||
my $v = $c->validation();
|
||||
my $v = $c->validation() if $c->req->method eq 'POST';
|
||||
|
||||
if ($c->req->method eq 'POST' && $v->has_data) {
|
||||
my $name = $c->param('name') || 'Anonymous';
|
||||
|
|
Loading…
Reference in a new issue