Some smol tweaks to appease perlcritic

This commit is contained in:
swagg boi 2022-04-22 12:44:19 -04:00
parent 1dc9d61832
commit d9ea2d78c4
3 changed files with 5 additions and 3 deletions

View file

@ -62,7 +62,9 @@ under sub ($c) {
get '/' => sub ($c) { $c->redirect_to(page => {page => 'view'}) };
any [qw{GET POST}], '/sign' => sub ($c) {
my $v = $c->validation() if $c->req->method eq 'POST';
my $v;
$v = $c->validation() if $c->req->method eq 'POST';
if ($v && $v->has_data) {
my $name = $c->param('name') || 'Anonymous';

View file

@ -7,7 +7,7 @@ use Mojo::Base -base, -signatures;
has 'pg';
sub new($class, $pg, $pg_object) {
bless {$pg => $pg_object}
bless {$pg => $pg_object}, $class
}
sub get_visitor_count($self) {

View file

@ -10,7 +10,7 @@ sub new($class, $pg, $pg_object) {
bless {
$pg => $pg_object,
max_posts => 5
}
}, $class
}
sub get_posts($self, $this_page = undef) {