diff --git a/lib/PostText.pm b/lib/PostText.pm index 610071a..d411b01 100644 --- a/lib/PostText.pm +++ b/lib/PostText.pm @@ -58,6 +58,10 @@ sub startup($self) { return undef; }); + $self->helper(is_admin => sub ($c) { + $c->session->{'is_admin'} || undef + }); + # Finish configuring some things $self->secrets($self->config->{'secrets'}) || die $@; diff --git a/templates/layouts/default.html.ep b/templates/layouts/default.html.ep index c708e93..12f3f1f 100644 --- a/templates/layouts/default.html.ep +++ b/templates/layouts/default.html.ep @@ -8,7 +8,6 @@

Post::Text